-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.prod.yml
75 lines (70 loc) · 1.92 KB
/
docker-compose.prod.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
include:
- path:
- docker/services/fonts.yml
- docker/services/umami.yml
- docker/services/certbot.yml
project_directory: .
services:
nginx:
container_name: wokalek-nginx
image: wokalek/nginx-brotli:${NGINX_VERSION:?error}
restart: always
depends_on:
- nuxt
- django
- umami
ports:
- 80:80
- 443:443
volumes:
- ./volumes/nginx/cache:/data/nginx/cache
- ./volumes/nginx/log:/var/log/nginx
- ./volumes/certbot/www:/certbot/www
- ./volumes/certbot/conf/live/wokalek.ru/fullchain.pem:/certbot/certs/fullchain.pem
- ./volumes/certbot/conf/live/wokalek.ru/privkey.pem:/certbot/certs/privkey.pem
- ./nginx/conf/prod.conf:/etc/nginx/nginx.conf
- ./nginx/snippets:/etc/nginx/snippets
- django-static:/django/static
- ./django/media:/django/media
nuxt:
container_name: wokalek-nuxt
build:
dockerfile: docker/nuxt/prod.Dockerfile
args:
- NODE_VERSION=${NUXT_NODE_VERSION:?error}
restart: always
depends_on:
fonts:
condition: service_completed_successfully
env_file: env/nuxt/.env
volumes:
- ./django/media:/nuxt/.output/public/media
django:
container_name: wokalek-django
build:
dockerfile: docker/django/prod.Dockerfile
args:
- PYTHON_VERSION=${DJANGO_PYTHON_VERSION:?error}
restart: always
depends_on:
database:
condition: service_healthy
env_file: env/django/.env
volumes:
- django-static:/static
- ./django:/django
database:
container_name: wokalek-database
image: postgres:${DATABASE_POSTGRES_VERSION:?error}
restart: always
shm_size: 256mb
env_file: env/database/.env
volumes:
- ./volumes/database/data:/var/lib/postgresql/data
healthcheck:
test: ['CMD-SHELL', 'pg_isready']
interval: 5s
timeout: 5s
retries: 5
volumes:
django-static: