hexabot/docker/docker-compose.nginx.prod.yml
2024-09-10 10:50:11 +01:00

19 lines
603 B
YAML

version: "3.8"
services:
nginx:
container_name: nginx
volumes:
- ./nginx/secure/:/etc/nginx:ro
- /etc/localtime:/etc/localtime:ro
- ./nginx/certbot/conf:/etc/letsencrypt
- ./nginx/certbot/www:/var/www/certbot
command: "/bin/sh -c 'while :; do sleep 6h & wait $${!}; nginx -s reload; done & nginx -g \"daemon off;\"'"
certbot:
image: certbot/certbot
volumes:
- ./nginx/certbot/conf:/etc/letsencrypt
- ./nginx/certbot/www:/var/www/certbot
entrypoint: "/bin/sh -c 'trap exit TERM; while :; do certbot renew; sleep 12h & wait $${!}; done;'"