-
Notifications
You must be signed in to change notification settings - Fork 3
/
docker-compose.yml
90 lines (78 loc) · 2.65 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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
version: '3.5'
x-base: &base
restart: always
networks:
- internal
x-env: &env
env_file:
- ${ENV_FILE:-./env}
x-backend-volumes: &backend_volumes
volumes:
- 'previews:${PREVIEW_FOLDER:?}'
- 'tmp:${TMP_DIR:-/tmp/zou}'
services:
kitsu:
<<: [*base, *env]
container_name: ${COMPOSE_PROJECT_NAME:?}-kitsu
image: registry.gitlab.com/mathbou/docker-cgwire/kitsu:${KITSU_VERSION:-latest}
depends_on:
- zou-app
- zou-event
- zou-jobs
zou-app:
<<: [*base,*env, *backend_volumes]
container_name: ${COMPOSE_PROJECT_NAME:?}-zou-app
image: registry.gitlab.com/mathbou/docker-cgwire/zou:${ZOU_VERSION:-latest}
depends_on:
- db
- indexer
command: "gunicorn --error-logfile - --access-logfile - -w 3 -k gevent -b :5000 zou.app:app"
zou-event:
<<: [*base, *env]
container_name: ${COMPOSE_PROJECT_NAME:?}-zou-event
image: registry.gitlab.com/mathbou/docker-cgwire/zou:${ZOU_VERSION:-latest}
depends_on:
- redis
command: "gunicorn --error-logfile - --access-logfile - -w 1 -k geventwebsocket.gunicorn.workers.GeventWebSocketWorker -b :5001 zou.event_stream:app"
zou-jobs:
<<: [*base, *env, *backend_volumes]
container_name: ${COMPOSE_PROJECT_NAME:?}-zou-jobs
image: registry.gitlab.com/mathbou/docker-cgwire/zou:${ZOU_VERSION:-latest}
command: "rq worker -c zou.job_settings"
db:
<<: *base
container_name: ${COMPOSE_PROJECT_NAME:?}-db-${DB_VERSION:?}
image: postgres:${DB_VERSION:?}-alpine
volumes:
- 'db:/var/lib/postgresql/data'
- ./db/pg_ctl.conf:/etc/postgresql/${DB_VERSION:?}/main/pg_ctl.conf:ro
environment:
- POSTGRES_PASSWORD=${DB_PASSWORD:?}
redis:
<<: *base
container_name: ${COMPOSE_PROJECT_NAME:?}-redis
image: redis:alpine
volumes:
- 'redis:/data'
indexer:
<<: *base
container_name: ${COMPOSE_PROJECT_NAME:?}-indexer
image: getmeili/meilisearch:${INDEXER_VERSION:?}
volumes:
- 'indexer:/meili_data'
environment:
- MEILI_MASTER_KEY=${INDEXER_KEY:?}
volumes:
db:
name: ${COMPOSE_PROJECT_NAME:?}-db-${DB_VERSION:?}
redis:
name: ${COMPOSE_PROJECT_NAME:?}-redis
previews:
name: ${COMPOSE_PROJECT_NAME:?}-previews
tmp:
name: ${COMPOSE_PROJECT_NAME:?}-tmp
indexer:
name: ${COMPOSE_PROJECT_NAME:?}-indexer
networks:
internal:
name: ${COMPOSE_PROJECT_NAME:?}-internal