-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
49 lines (41 loc) · 1.31 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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
.PHONY: help
help:
@echo 'Usage: make [TARGET] [EXTRA_ARGUMENTS]'
@echo ''
@echo 'Service targets:'
@echo ' start start all services in the background or just the one specified by service= argument'
@echo ' stop stop all services or just the one specified by service= argument'
@echo ' restart restart all services or just the one specified by service= argument'
@echo ' down down all services and remove their data/images/etc.'
@echo ' ps show status of all services or just the one specified by service= argument'
@echo ' logs show logs of all services or just the one specified by service= argument'
@echo ''
@echo 'Tool targets:'
@echo ' connect-bot connect to the local bot interface to send commands'
@echo ' redis-cli run redis-cli within the redis container'
@echo ''
.PHONY: start
start:
@docker compose up -d $(service)
.PHONY: stop
stop:
@docker compose stop $(service)
.PHONY: restart
restart:
@docker compose stop $(service)
@docker compose up -d $(service)
.PHONY: down
down:
@docker compose down --rmi local --volumes
.PHONY: ps
ps:
@docker compose ps
.PHONY: logs
logs:
@docker compose logs --tail=100 -f $(service)
.PHONY: connect-bot
connect-bot:
@nc localhost 5000
.PHONY: redis-cli
redis-cli:
@docker compose exec redis redis-cli