From 18f1057722ecbb0b7969bec7d3ac6caf2f9681a1 Mon Sep 17 00:00:00 2001 From: Andreas Granig Date: Thu, 8 Aug 2013 12:57:17 +0200 Subject: [PATCH] Only disable other sites if they are enabled. --- debian/ngcp-panel.postinst | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/debian/ngcp-panel.postinst b/debian/ngcp-panel.postinst index 5fa2aff45c..6e83d562dc 100644 --- a/debian/ngcp-panel.postinst +++ b/debian/ngcp-panel.postinst @@ -22,10 +22,14 @@ a2enmod ssl perl a2enmod dump_io || echo "Missing some optional Apache module(s), ignoring." # disable debian's default Apache site -a2dissite default +if [ -e /etc/apache2/sites-enabled/default ]; then + a2dissite default +fi # disable old ngcp-www-admin -a2dissite ngcp-www-admin +if [ -e /etc/apache2/sites-enabled/ngcp-www-admin ]; then + a2dissite ngcp-www-admin +fi # reload perl and/or apache modules if [ -x /etc/init.d/apache2 ] ; then