nginx-proxy/update_certs.sh

20 lines
493 B
Bash
Raw Normal View History

#!/bin/bash
2020-11-29 11:33:31 +00:00
# if [ $(id -u) -ne 0 ]; then
# echo "This script must be run as root." > /dev/stderr
# exit 1
# fi
domains=$(cat domains.list | grep -v -E '^[[:space:]]*(#.*)?$')
docker exec -it nginx_proxy mkdir -p /var/www/certbot
$(dirname $0)/certbot \
certonly \
--agree-tos --renew-by-default \
--force-renewal \
--cert-name typename.fr \
-d $(echo typename.fr ${domains[*]} | tr ' ' ',')
2023-06-04 19:02:28 +00:00
docker compose restart