1
0
mirror of https://github.com/mail-in-a-box/mailinabox.git synced 2024-11-26 02:57:04 +00:00

the cron job to re-sign DNSSEC zones wasnt working after adding the API key to the management daemon because the script relied on a bash-ism but cron runs it with (probably) sh

This commit is contained in:
Joshua Tauberer 2014-07-19 16:31:05 +00:00
parent 37fcc5b53d
commit 65c3a44e63

4
setup/dns.sh Normal file → Executable file
View File

@ -1,3 +1,4 @@
#!/bin/bash
# DNS: Configure a DNS server using nsd # DNS: Configure a DNS server using nsd
####################################### #######################################
@ -65,10 +66,9 @@ fi
# Force the dns_update script to be run every day to re-sign zones for DNSSEC. # Force the dns_update script to be run every day to re-sign zones for DNSSEC.
cat > /etc/cron.daily/mailinabox-dnssec << EOF; cat > /etc/cron.daily/mailinabox-dnssec << EOF;
#!/bin/bash
# Mail-in-a-Box # Mail-in-a-Box
# Re-sign any DNS zones with DNSSEC because the signatures expire periodically. # Re-sign any DNS zones with DNSSEC because the signatures expire periodically.
curl -d GO --user \$(</var/lib/mailinabox/api.key): http://localhost:10222/dns/update `pwd`/tools/dns_update
EOF EOF
chmod +x /etc/cron.daily/mailinabox-dnssec chmod +x /etc/cron.daily/mailinabox-dnssec