-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
35 lines (26 loc) · 1.16 KB
/
Makefile
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
.PHONY: show-help start stop down nuke inspect-backend inspect-cli
.DEFAULT_GOAL := show-help
show-help:
@echo 'Available Commands:'
@echo ' build | Builds all containers.'
@echo ' start | Starts all containers.'
@echo ' stop | Stops all running containers.'
@echo ' down | Stops containers, clears volumes & networks. If things are not working as expected, you likely want to run this command.'
@echo ' nuke | Clears all images, containers, networks, and volumes. If all else fails, run this command.'
@echo ' inspect-<SERVICE> | Runs bash inside the running service container.'
build:
COMPOSE_DOCKER_CLI_BUILD=1 DOCKER_BUILDKIT=1 docker-compose --file services/docker-compose.yaml build
start:
docker-compose --file services/docker-compose.yaml up --renew-anon-volumes
stop:
docker stop `docker ps -aq`
down:
docker-compose --file services/docker-compose.yaml down -v
nuke:
- docker stop `docker ps -aq`
- @echo 'Note: this may take a while'
- docker system prune --all --volumes
inspect-backend:
docker-compose --file services/docker-compose.yaml exec backend /bin/bash
inspect-cli:
docker-compose --file services/docker-compose.yaml exec cli /bin/bash