Files

18 lines
496 B
Bash
Raw Permalink Normal View History

2025-11-30 11:50:11 +01:00
#!/bin/sh
# Certbot entrypoint script
# Se vengono passati argomenti, esegui il comando direttamente
# Altrimenti, esegui il loop di auto-renewal
if [ $# -eq 0 ]; then
# Nessun argomento: modalità auto-renewal
echo "Starting certbot auto-renewal service..."
trap exit TERM
while :; do
certbot renew --webroot --webroot-path=/var/www/certbot --quiet
sleep 12h & wait ${!}
done
else
# Argomenti passati: esegui il comando certbot
exec certbot "$@"
fi