This repository has been archived by the owner on Nov 6, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Makefile.local.mk
40 lines (31 loc) · 1.64 KB
/
Makefile.local.mk
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
all: help
## dev-prepare-up: Run migration before doing up
dev-prepare-up:
docker-compose -f docker-compose.yaml -f docker-compose.dev.yaml run migration
## dev-daemon: Startup with docker process in background (to stop afterwards use make clean)
dev-daemon: dev-prepare-up
docker-compose -f docker-compose.yaml -f docker-compose.dev.yaml up -d frontend
## dev-fg: Startup with docker process in foreground
dev-fg: dev-prepare-up
docker-compose -f docker-compose.yaml -f docker-compose.dev.yaml up frontend
## dev-debug: Startup clean docker process in background, and docker attach to foreground for debugging
dev-debug: clean dev-daemon
docker attach $(shell sh -c "docker-compose ps -q frontend")
## dev-attach: Attach to existing running background docker process for purposes of debugging
dev-attach:
docker attach $(shell sh -c "docker-compose ps -q frontend")
## dev-py: Start django shell (in the dev-packages context) in new container
dev-py:
docker-compose -f docker-compose.yaml -f docker-compose.dev.yaml run frontend sh -c "dev-packages/bin/python manage.py shell"
## dev-run: Start shell in new copy of container
dev-run:
docker-compose -f docker-compose.yaml -f docker-compose.dev.yaml run --rm frontend bash
## dev-exec: Exec into shell of existing container
dev-exec:
docker-compose -f docker-compose.yaml -f docker-compose.dev.yaml exec frontend bash
test-wip: DJANGO_SETTINGS_MODULE=controlpanel.settings.test
test-wip:
@echo
@echo "> Running Python Tests (In Docker)..."
@docker-compose -f docker-compose.yaml -f docker-compose.dev.yaml run --rm -e KUBECONFIG=tests/kubeconfig \
frontend sh -c "pytest tests --color=yes -m indevelopment"