mirror of
https://github.com/zyberzero/certbot-rfc2136.git
synced 2024-10-29 22:44:27 +01:00
12 lines
336 B
Bash
12 lines
336 B
Bash
|
#!/usr/bin/env bash
|
||
|
set -e
|
||
|
set -u
|
||
|
set -o pipefail
|
||
|
|
||
|
NSUPDATE="nsupdate -k /path/to/private"
|
||
|
DNSSERVER="masterns.yourdomain.tld"
|
||
|
ZONE="yourzonename.tld"
|
||
|
TTL=300
|
||
|
|
||
|
printf "server %s\nzone %s.\nupdate add _acme-challenge.%s. %d in TXT \"%s\"\nsend\n" "${DNSSERVER}" "${ZONE}" "${CERTBOT_DOMAIN}" "${TTL}" "${CERTBOT_VALIDATION}" | $NSUPDATE
|