Skip to content

Commit 1fa53e9

Browse files
author
Marius Burkard
committed
Merge branch '6191-improve-letsencrypt-renew-hook' into 'develop'
Resolve "improve letsencrypt renew hook" Closes #6191 See merge request ispconfig/ispconfig3!1492
2 parents efc59b6 + 22e34a1 commit 1fa53e9

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

server/scripts/letsencrypt_renew_hook.sh

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,12 @@
1212

1313
## If you need a custom hook file, create a file with the same name in
1414
## /usr/local/ispconfig/server/conf-custom/scripts/
15+
##
16+
## End the file with 'return 124' to signal that this script should not terminate.
1517
if [ -e "/usr/local/ispconfig/server/conf-custom/scripts/letsencrypt_renew_hook.sh" ] ; then
16-
. /usr/local/ispconfig/server/conf-custom/scripts/letsencrypt_renew_hook.sh && exit 0 || exit 1;
18+
. /usr/local/ispconfig/server/conf-custom/scripts/letsencrypt_renew_hook.sh
19+
ret=$?
20+
if [ $ret != 124 ]; then exit $ret; fi
1721
fi
1822

1923
hostname=$(hostname -f)
@@ -52,4 +56,4 @@ if [ -d "$lelive" ]; then
5256
if [ $(dpkg-query -W -f='${Status}' nginx 2>/dev/null | grep -c "ok installed") -eq 1 ]; then service nginx restart; fi
5357
if [ $(dpkg-query -W -f='${Status}' apache2 2>/dev/null | grep -c "ok installed") -eq 1 ]; then service apache2 restart; fi
5458
fi
55-
else echo `/bin/date` "Your Lets Encrypt SSL certs path for your ISPConfig server FQDN is missing.$line" >> /var/log/ispconfig/ispconfig.log; fi
59+
else echo `/bin/date` "Your Lets Encrypt SSL certs path for your ISPConfig server FQDN is missing.$line" >> /var/log/ispconfig/ispconfig.log; fi

0 commit comments

Comments
 (0)