[Pkg-nagios-changes] [SCM] Debian packaging of icinga-web branch, master, updated. debian/1.9.0+dfsg1-1-8-g4d8b05d

Markus Frosch markus at lazyfrosch.de
Mon Jun 24 09:55:19 UTC 2013


The following commit has been merged in the master branch:
commit adf9c48f72ae5e00e2c3db77865e519774c5ac2f
Author: Markus Frosch <markus at lazyfrosch.de>
Date:   Mon Jun 24 11:15:08 2013 +0200

    Removed debconf integration for httpd selection

diff --git a/debian/icinga-web.config b/debian/icinga-web.config
index 7236219..b1817eb 100644
--- a/debian/icinga-web.config
+++ b/debian/icinga-web.config
@@ -15,45 +15,6 @@ if [ -f /usr/share/dbconfig-common/dpkg/config ]; then
 fi
 
 ###
-# Configure web server
-###
-
-# (taken from the webapps-common httpd functions)
-# wc_httpd_installed: test for installed httpds
-# usage:
-#       wc_httpd_installed [ httpd1 httpd2 ... ]
-#
-# no arguments implies to test for all servers
-wc_httpd_installed(){
-        local httpds
-        if [ "$*" ]; then
-                httpds=$*
-        else
-                httpds=$wc_httpd_supported
-        fi
-        for f in $httpds; do
-                if test -x /usr/sbin/$f; then
-                        echo $f
-                fi
-        done
-}
-
-
-# list of installed servers to check for
-default_servers=`wc_httpd_installed apache2`
-# convert list to comma seperated list
-server_list=`echo $default_servers | sed -e 's/[[:space:]][[:space:]]*/, /g'`
-
-# if they haven't already been prompted, preseed the server selection
-db_fget icinga-web/httpd seen
-if [ "$RET" = "false" ]; then
-    db_set icinga-web/httpd $server_list
-fi
-
-db_input high icinga-web/httpd || true
-db_go || true
-
-###
 # Configure the root password for icinga-web
 # only when dbconfig-common is used...
 ###
diff --git a/debian/icinga-web.postinst b/debian/icinga-web.postinst
index 3c3d749..530244f 100644
--- a/debian/icinga-web.postinst
+++ b/debian/icinga-web.postinst
@@ -70,41 +70,20 @@ generate_dbxml /etc/icinga-web/conf.d/database-ido.xml \
                /etc/dbconfig-common/icinga-idoutils.conf
 
 ###
-# webservers (currently only Apache2)
+# Apache2
 ###
 
-# get the list of selected servers
-db_get icinga-web/httpd
-servers=$(echo $RET | sed -e 's/,/ /g')
+if [ "$1" = "configure" ] && [ -x "/usr/sbin/apache2" ]; then
+    echo "enabling Apache2 config..."
 
-# check for activated servers
-for server in $servers; do
-    if [ "$server" = "apache2" ]; then
-        echo "enabling config for webserver $server..."
+    # enable mod rewrite
+    [ -f /etc/apache2/mods-enabled/rewrite.load ] || a2enmod rewrite
 
-        # enable mod rewrite
-        [ -f /etc/apache2/mods-enabled/rewrite.load ] || a2enmod rewrite
-        
-        # create symlink if not existing
-        [ -f /etc/apache2/conf.d/icinga-web.conf ] || ln -vs ../../icinga-web/apache2.conf /etc/apache2/conf.d/icinga-web.conf
-        
-        # reload webserver
-        [ -x $(which invoke-rc.d) ] && invoke-rc.d apache2 reload
-    else
-        echo "warning: webserver $server is not supported!"
-    fi
-done
-
-# check for not wanted servers
-if ! echo $servers | grep -q "apache2"; then
-    # remove link if exists
-    if [ -L /etc/apache2/conf.d/icinga-web.conf ]; then
-        echo "removing config for webserver apache2"
-        rm -f /etc/apache2/conf.d/icinga-web.conf
-        
-        # reload webserver
-        [ -x $(which invoke-rc.d) ] && invoke-rc.d apache2 reload
-    fi
+    # create symlink if not existing
+    [ -f /etc/apache2/conf.d/icinga-web.conf ] || ln -vs ../../icinga-web/apache2.conf /etc/apache2/conf.d/icinga-web.conf
+
+    # reload webserver
+    [ -x $(which invoke-rc.d) ] && invoke-rc.d apache2 reload
 fi
 
 ###

-- 
Debian packaging of icinga-web



More information about the Pkg-nagios-changes mailing list