Просмотр исходного кода

Ubuntu fix when spamassassin isn't in startup list

Patch is ported from Debian installer (old and tested).
Fix for https://bugs.vestacp.com/issues/461
dpeca 9 лет назад
Родитель
Сommit
61a12e4cd9
1 измененных файлов с 3 добавлено и 0 удалено
  1. 3 0
      install/vst-install-ubuntu.sh

+ 3 - 0
install/vst-install-ubuntu.sh

@@ -1081,6 +1081,9 @@ if [ "$spamd" = 'yes' ]; then
     sed -i "s/ENABLED=0/ENABLED=1/" /etc/default/spamassassin
     service spamassassin start
     check_result $? "spamassassin start failed"
+    if [[ $(systemctl list-unit-files | grep spamassassin) =~ "disabled" ]]; then
+        systemctl enable spamassassin
+    fi
 fi