-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
32 lines (23 loc) · 738 Bytes
/
Makefile
File metadata and controls
32 lines (23 loc) · 738 Bytes
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
VOLUME_DIR := /home/hojsong/data
DOCKER_COMPOSE := docker-compose
DOCKER_COMPOSE_FILE := ./srcs/docker-compose.yml
PROJECT_NAME := Inception
NETWORK_NAME := network-inception
all:
@mkdir -p $(VOLUME_DIR)/db
@mkdir -p $(VOLUME_DIR)/wordpress
$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) up --build -d
logs:
$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) logs
up:
$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) up
down:
$(DOCKER_COMPOSE) -f $(DOCKER_COMPOSE_FILE) down
clean: down
docker system prune -f --all # Remove all unused images not just dangling ones
fclean: clean
@rm -rf $(VOLUME_DIR)/db/*
@rm -rf $(VOLUME_DIR)/wordpress/*
@docker volume rm $$(docker volume ls -q)
re: fclean all
.PHONY: re fclean all clean down up