-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
56 lines (51 loc) · 982 Bytes
/
docker-compose.yml
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
50
51
52
53
54
55
56
version: '3'
volumes:
db:
services:
db:
image: mariadb
restart: always
command: --transaction-isolation=READ-COMMITTED
environment:
MYSQL_ROOT_PASSWORD: root_password
MYSQL_DATABASE: ${DB_DATABASE}
MYSQL_USER: ${DB_USER}
MYSQL_PASSWORD: ${DB_PASSWORD}
volumes:
- ./db:/docker-entrypoint-initdb.d:ro
- db:/var/lib/mysql
# ports:
# - 3306:3306
redis:
image: redis
restart: always
worker:
image: 127.0.0.1:5000/hermod-api
build: .
command: rq worker --url=redis://redis:6379
restart: always
depends_on:
- db
- redis
env_file:
- .env
deploy:
replicas: 1
web:
image: 127.0.0.1:5000/hermod-api
build: .
restart: always
depends_on:
- db
- redis
- worker
env_file:
- .env
# environment:
# FLASK_ENV: development
ports:
- 9090:9090
# cap_add:
# - SYS_PTRACE
# deploy:
# replicas: 1