]> granicus.if.org Git - icinga2/commitdiff
RPM spec: don't enable features after an upgrade
authorAlexander A. Klimov <alexander.klimov@icinga.com>
Thu, 4 May 2017 15:11:20 +0000 (17:11 +0200)
committerGunnar Beutner <gunnar.beutner@icinga.com>
Thu, 11 May 2017 08:26:25 +0000 (10:26 +0200)
fixes #4621
fixes #5226

Signed-off-by: Gunnar Beutner <gunnar.beutner@icinga.com>
icinga2.spec

index 5b37ecfc85a9b566e3f483f2be0d11e3a9d95127..cc01327de312ddae94ff15473d491886e935b736 100644 (file)
@@ -469,10 +469,13 @@ getent passwd %{icinga_user} >/dev/null || %{_sbindir}/useradd -c "icinga" -s /s
 %fillup_and_insserv %{name}
 %endif
 
-# initial installation, enable default features
-for feature in checker notification mainlog; do
-       ln -sf ../features-available/${feature}.conf %{_sysconfdir}/%{name}/features-enabled/${feature}.conf
-done
+if [ ${1:-0} -eq 1 ]
+then
+       # initial installation, enable default features
+       for feature in checker notification mainlog; do
+               ln -sf ../features-available/${feature}.conf %{_sysconfdir}/%{name}/features-enabled/${feature}.conf
+       done
+fi
 
 exit 0