diff options
-rw-r--r-- | debian/changelog | 6 | ||||
-rw-r--r-- | debian/sitesummary.postinst | 12 |
2 files changed, 17 insertions, 1 deletions
diff --git a/debian/changelog b/debian/changelog index 8412a74..b1bc677 100644 --- a/debian/changelog +++ b/debian/changelog @@ -4,7 +4,11 @@ sitesummary (0.0.56) UNRELEASED; urgency=low from Nagios v3 instead of the old one which was based on debian-edu- config. * Provide more time periods (workhours, nonworkhours, never) for the - Nagios configuration + Nagios configuration. + * Make sure to create a dummy Nagios configuration during + installation when Nagios autoconfiguration is enabled, to make + sure Nagios start on first boot when sitesummary is installed from + debian-installer. -- Petter Reinholdtsen <pere@debian.org> Tue, 19 Jan 2010 10:07:24 +0100 diff --git a/debian/sitesummary.postinst b/debian/sitesummary.postinst index aa08ae1..d828ab7 100644 --- a/debian/sitesummary.postinst +++ b/debian/sitesummary.postinst @@ -42,6 +42,18 @@ case "$1" in mkdir -p $(dirname $config) echo 'NAGIOSCFG="/etc/nagios3/sitesummary.cfg"' \ >> /etc/default/nagios3 + if [ ! -f /var/lib/sitesummary/nagios-generated.cfg ] ; then + # Create dummy file to make sure nagios will start + # on first boot if sitesummary is installed using + # debian-installer + cat > /var/lib/sitesummary/nagios-generated.cfg <<EOF +define host { + use server-host + host_name localhost + address localhost +} +EOF + fi fi fi |