Ensure that letsencrypt cert is obtained for xmpp when not in onion only mode

This commit is contained in:
Bob Mottram 2017-05-21 20:12:01 +01:00
parent 1c7cfc8926
commit 1a9f1a9e20
1 changed files with 8 additions and 5 deletions

View File

@ -809,11 +809,14 @@ function install_xmpp {
update_prosody_modules update_prosody_modules
if [[ $ONION_ONLY == 'no' ]]; then # obtain a cert for the default domain
# obtain a cert for the default domain if [[ "$(cert_exists ${DEFAULT_DOMAIN_NAME} pem)" == "0" ]]; then
if [[ "$(cert_exists ${DEFAULT_DOMAIN_NAME} pem)" == "0" ]]; then create_site_certificate ${DEFAULT_DOMAIN_NAME} 'yes'
echo $'Obtaining certificate for the main domain' if [[ $ONION_ONLY == 'no' ]]; then
create_site_certificate ${DEFAULT_DOMAIN_NAME} 'yes' if [[ "$(cert_exists ${DEFAULT_DOMAIN_NAME} pem)" == "0" ]]; then
echo $'LetsEncrypt cert could not be obtained for xmpp'
exit 72342
fi
fi fi
fi fi