mirror of
https://github.com/mail-in-a-box/mailinabox.git
synced 2026-03-23 18:57:23 +01:00
setup dns authentication for letsencrypt
This commit is contained in:
@@ -1,2 +1,10 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# TODO: Make work with port other than 443
|
||||
|
||||
API_KEY=`cat /var/lib/mailinabox/api.key`
|
||||
HOSTNAME=`hostname`
|
||||
|
||||
curl -s -X PUT -d "$CERTBOT_VALIDATION" --user "$API_KEY:" https://$HOSTNAME/admin/dns/custom/_acme-challenge.$CERTBOT_DOMAIN/TXT
|
||||
|
||||
sleep 15
|
||||
|
||||
8
tools/dns-cleanup.sh
Executable file
8
tools/dns-cleanup.sh
Executable file
@@ -0,0 +1,8 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# TODO: Make work with port other than 443
|
||||
|
||||
API_KEY=`cat /var/lib/mailinabox/api.key`
|
||||
HOSTNAME=`hostname`
|
||||
|
||||
curl -s -X DELETE --user "$API_KEY:" https://$HOSTNAME/admin/dns/custom/_acme-challenge.$CERTBOT_DOMAIN/TXT
|
||||
Reference in New Issue
Block a user