certbot-ovh/certbot-ovh.sh
2022-06-24 16:22:19 +02:00

19 lines
462 B
Bash
Executable file

#!/usr/bin/env sh
yes_options="
1
y
t
"
if [ -n "$CERTBOT_OVH_AGREE_TOS" ] && echo "$yes_options" | grep -wiq "$CERTBOT_OVH_AGREE_TOS"; then
agree_tos=--agree-tos
else
agree_tos=
fi
# shellcheck disable=SC2086
certbot certonly --preferred-challenges dns-01 --keep \
--email="$CERTBOT_OVH_LE_EMAIL" --domains="$CERTBOT_OVH_DOMAINS" \
--no-eff-email --manual-public-ip-logging-ok \
--dns-ovh --dns-ovh-credentials /etc/certbot-ovh.ini $agree_tos