1
0
Fork 0
mirror of https://github.com/fernwerker/ownDynDNS.git synced 2025-07-11 22:45:43 +02:00

added certbot compose and auth hook

This commit is contained in:
niiwiicamo 2024-07-24 13:37:15 +02:00
parent 25e4773288
commit e90f67e342
2 changed files with 43 additions and 7 deletions

15
auth-hook.sh Executable file
View file

@ -0,0 +1,15 @@
# ownDynDNS auth script for certbot dns-01 challenge
# install curl
$(apk --no-cache add curl)
ACME_PREFIX="_acme-challenge"
if [ -z "${DDNS_HOST}" ]; then DDNS_HOST=${ACME_PREFIX}; else DDNS_HOST=${ACME_PREFIX}.${DDNS_HOST}; fi
PAYLOAD="force=true&user=${DDNS_USER}&password=${DDNS_PASS}&txt=${CERTBOT_VALIDATION}&domain=${DDNS_DOMAIN}&host=${DDNS_HOST}&create=true"
# echo ${PAYLOAD}
curl -sSL -X POST --data "${PAYLOAD}" ${DDNS_SCRIPT} \
&& sleep 300