mirror of
https://github.com/openmhz/trunk-server.git
synced 2026-11-13 01:07:42 -05:00
auto let's encrypt
This commit is contained in:
@@ -18,12 +18,21 @@ services:
|
||||
volumes:
|
||||
- ${PWD}/data/log/syslog:/var/log/syslog
|
||||
- ${PWD}/data/log/nginx:/var/log/nginx
|
||||
- ${PWD}/data/certbot/www/:/var/www/certbot/:ro
|
||||
- ${PWD}/data/certbot/conf/:/etc/letsencrypt/:ro
|
||||
depends_on:
|
||||
- backend
|
||||
- frontend
|
||||
- account
|
||||
- admin
|
||||
command: /bin/bash -c "envsubst '$$DOMAIN_NAME' < /etc/nginx/conf.d/site.template > /etc/nginx/conf.d/default.conf && nginx -g 'daemon off;'"
|
||||
command: /bin/bash -c "envsubst '$$DOMAIN_NAME' < /etc/nginx/conf.d/site.template > /etc/nginx/conf.d/default.conf && while :; do sleep 6h & wait $${!}; nginx -s reload; done & nginx -g 'daemon off;'"
|
||||
|
||||
certbot:
|
||||
image: certbot/certbot:latest
|
||||
volumes:
|
||||
- ${PWD}/data/certbot/www/:/var/www/certbot/:rw
|
||||
- ${PWD}/data/certbot/conf/:/etc/letsencrypt/:rw
|
||||
entrypoint: "/bin/sh -c 'trap exit TERM; while :; do certbot renew; sleep 12h & wait $${!}; done;'"
|
||||
|
||||
mongo:
|
||||
build:
|
||||
|
||||
Reference in New Issue
Block a user