-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose-prod.yml
More file actions
29 lines (29 loc) · 1011 Bytes
/
docker-compose-prod.yml
File metadata and controls
29 lines (29 loc) · 1011 Bytes
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
version: '3.9'
services:
app:
build: .
nginx:
container_name: 'anovote_proxy'
image: nginx:1.15-alpine
ports:
- '80:80'
- '443:443'
volumes:
- ../frontend/build:/www/
- ../http/nginx:/etc/nginx/conf.d
- ../http/certbot/conf:/etc/letsencrypt
- ../http/certbot/www:/var/www/certbot
networks:
# Comes from main docker-compose
- anovote_proxy
command: '/bin/sh -c ''while :; do sleep 6h & wait $${!}; nginx -s reload; done & nginx -g "daemon off;"'''
certbot:
container_name: 'anovote_certbot'
image: certbot/certbot
volumes:
- ../http/certbot/conf:/etc/letsencrypt
- ../http/certbot/www:/var/www/certbot
networks:
# Comes from main docker-compose
- anovote_proxy
entrypoint: "/bin/sh -c 'trap exit TERM; while :; do certbot renew; sleep 12h & wait $${!}; done;'"