20 lines
446 B
Bash
20 lines
446 B
Bash
|
#!/usr/bin/env sh
|
||
|
|
||
|
# Start cron
|
||
|
/usr/sbin/crond -d 8 &
|
||
|
|
||
|
# Renew all certificates
|
||
|
for url in $(env | grep '^[^=]\+_DOMAIN=' | sed 's/^.*\?=\(.*\)$/\1/g') $(echo "$DOMAINS" | sed 's/,/ /g')
|
||
|
do
|
||
|
cerbot certonly \
|
||
|
--standalone \
|
||
|
-d "$url" \
|
||
|
--email "$EMAIL" \
|
||
|
-n \
|
||
|
--agree-tos \
|
||
|
--expand
|
||
|
done
|
||
|
|
||
|
# The original script handles the template subsitution
|
||
|
exec /docker-entrypoint.sh nginx -g "daemon off;"
|