rotate-session-ticket-keys: improve error handling

This commit is contained in:
Daniel Micay 2025-08-11 00:00:57 -04:00
parent c5a724ea7e
commit 2db3740436

View file

@ -15,10 +15,14 @@ cat {1..4}.key > keys.new
rsync -I keys.new keys
rm keys.new
status=0
if systemctl is-enabled nginx.service >/dev/null; then
nginx -s reload
nginx -s reload || status=1
fi
if systemctl is-enabled dnsdist.service >/dev/null; then
dnsdist -c -e 'reloadAllCertificates()'
dnsdist -c -e 'reloadAllCertificates()' || status=1
fi
exit $status