-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathdocker-compose.yml
76 lines (71 loc) · 2.08 KB
/
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
version: "2"
services:
nginx:
restart: always
image: nginx:1.12-alpine
ports:
- 8000:8000
volumes:
- ./docker/nginx/default.conf:/etc/nginx/conf.d/default.conf
- static_volume:/app/backend/blockserver/django_static
mysql:
restart: always
image: mysql/mysql-server:5.6
ports:
- "127.0.0.1:3306:3306"
volumes:
- ./docker/mysql/data:/var/lib/mysql
command: [
'--character-set-server=utf8',
'--collation-server=utf8_unicode_ci'
]
environment:
MYSQL_ROOT_PASSWORD: "root"
MYSQL_DATABASE: "quant"
MYSQL_USER: "quant"
MYSQL_PASSWORD: "quant001@"
redis:
image: redis:3.0-alpine
restart: unless-stopped
ports:
- "127.0.0.1:6378:6379"
#build:
# context: .
# dockerfile: ./docker/redis/
volumes:
- ./docker/redis/redis.conf:/usr/local/etc/redis/redis.conf
- ./docker/redis/data/:/data/
command:
redis-server /usr/local/etc/redis/redis.conf
rabbitmq:
image: rabbitmq:3.6-management
restart: unless-stopped
ports:
- "127.0.0.1:5672:5672"
- "15672:15672"
volumes:
- ./docker/rabbitmq/data:/var/lib/rabbitmq:rw
- ./docker/rabbitmq/rabbitmq.config:/etc/rabbitmq/rabbitmq.config:ro
- ./docker/rabbitmq/definitions.json:/etc/rabbitmq/definitions.json:ro
asgiserver:
extends:
file: docker-common.yml
service: backend
entrypoint: /app/docker/backend/asgi-entrypoint.sh
links:
- mysql
- redis
- rabbitmq
expose:
- 8000
worker:
extends:
file: docker-common.yml
service: backend
entrypoint: /app/docker/backend/worker-entrypoint.sh
links:
- mysql
- redis
- rabbitmq
volumes:
static_volume: {}