-
Notifications
You must be signed in to change notification settings - Fork 4
/
compose.override.production.yml
91 lines (83 loc) · 2.12 KB
/
compose.override.production.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
91
---
volumes:
production_postgres_data: {}
production_postgres_data_backups: {}
production_redis_data: {}
production_nginx: {}
services:
django:
build:
dockerfile: ./compose/production/django/Dockerfile
image: scram_production_django
env_file:
- ./.envs/.production/.django
- ./.envs/.production/.postgres
- /etc/vault.d/secrets/kv_root_security.env
volumes:
- ./staticfiles:/staticfiles
healthcheck:
test: ["CMD", "curl", "-f", "http://django:5000/process_expired/"]
postgres:
volumes:
- production_postgres_data:/var/lib/postgresql/data:Z
- production_postgres_data_backups:/backups:z
env_file:
- ./.envs/.production/.postgres
- /etc/vault.d/secrets/kv_root_security.env
deploy:
replicas: ${POSTGRES_ENABLED:-0}
nginx:
image: nginx:1.19
restart: on-failure:5
depends_on:
- django
networks:
default: {}
sysctls:
- net.ipv6.conf.all.disable_ipv6=0
environment:
- HOSTNAME=${HOSTNAME}
volumes:
- ./compose/production/nginx/nginx.conf:/etc/nginx/conf.d/default.conf
- /etc/letsencrypt/live/${HOSTNAME}/fullchain.pem:/etc/ssl/server.crt
- /etc/letsencrypt/live/${HOSTNAME}/privkey.pem:/etc/ssl/server.key
- ./staticfiles:/staticfiles
ports:
- "443:443"
- "80:80"
redis:
volumes:
- production_redis_data:/var/lib/redis:Z
gobgp:
volumes:
- ./gobgp_config:/config:z
networks:
default: {}
peering:
ipv4_address: ${SCRAM_V4_ADDRESS}
ipv6_address: ${SCRAM_V6_ADDRESS}
ports:
- "179:179"
- "50051"
translator:
env_file:
- ./.envs/.production/.translator
networks:
default:
enable_ipv6: true
ipam:
driver: default
config:
- subnet: 0200:c0:ff:ee::/64
peering:
enable_ipv6: true
driver: macvlan
driver_opts:
parent: ${SCRAM_PEERING_IFACE}
ipam:
driver: default
config:
- subnet: ${SCRAM_V4_SUBNET}
gateway: ${SCRAM_V4_GATEWAY}
- subnet: ${SCRAM_V6_SUBNET}
gateway: ${SCRAM_V6_GATEWAY}