-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathdocker-compose.yml
31 lines (27 loc) · 925 Bytes
/
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
version: '3'
services:
nginx:
image: nginx
network_mode: host
restart: unless-stopped
volumes:
- ./letsencrypt:/etc/letsencrypt:ro
- http_challenge:/var/www/.well-known:ro
- ./scripts:/scripts
- ./config:/config
- ./manual-configuration-files:/manual-configuration-files
- /root/sites/static:/var/www/sites/static
command: /bin/bash -c "/scripts/generate-config.sh && cp /manual-configuration-files/*.conf /etc/nginx/conf.d/ && exec nginx -g 'daemon off;'"
certbot:
image: certbot/certbot
volumes:
- ./letsencrypt:/etc/letsencrypt
- http_challenge:/var/www/.well-known
- ./scripts:/scripts
- ./config:/config
depends_on:
- nginx
entrypoint: sh -c
command: certbot renew
volumes:
http_challenge: ~