This commit is contained in:
Bob Mottram 2017-05-17 20:16:28 +01:00
parent 5e4ad87cab
commit ba1c7c26b7
1 changed files with 4 additions and 4 deletions

View File

@ -845,11 +845,11 @@ function install_xmpp {
cp -a /etc/prosody/conf.avail/example.com.cfg.lua /etc/prosody/conf.avail/xmpp.cfg.lua
if [[ "$(cert_exists ${DEFAULT_DOMAIN_NAME} pem)" == "1" ]]; then
sed -i "s|key =.*|key = /etc/ssl/private/${DEFAULT_DOMAIN_NAME}.key;|g" /etc/prosody/conf.avail/xmpp.cfg.lua
sed -i "s|certificate =.*|certificate = /etc/ssl/certs/${DEFAULT_DOMAIN_NAME}.pem;|g" /etc/prosody/conf.avail/xmpp.cfg.lua
sed -i "s|key =.*|key = \"/etc/ssl/private/${DEFAULT_DOMAIN_NAME}.key\";|g" /etc/prosody/conf.avail/xmpp.cfg.lua
sed -i "s|certificate =.*|certificate = \"/etc/ssl/certs/${DEFAULT_DOMAIN_NAME}.pem\";|g" /etc/prosody/conf.avail/xmpp.cfg.lua
else
sed -i "s|key =.*|key = /etc/ssl/privates/xmpp.key;|g" /etc/prosody/conf.avail/xmpp.cfg.lua
sed -i "s|certificate =.*|certificate = /etc/ssl/certs/xmpp.crt;|g" /etc/prosody/conf.avail/xmpp.cfg.lua
sed -i "s|key =.*|key = \"/etc/ssl/privates/xmpp.key\";|g" /etc/prosody/conf.avail/xmpp.cfg.lua
sed -i "s|certificate =.*|certificate = \"/etc/ssl/certs/xmpp.crt\";|g" /etc/prosody/conf.avail/xmpp.cfg.lua
fi
if ! grep -q "xmpp.dhparam" /etc/prosody/conf.avail/xmpp.cfg.lua; then
if [[ "$(cert_exists ${DEFAULT_DOMAIN_NAME})" == "1" ]]; then