From 3adc8e861dda15101d241ac7c1d62d717ea2bf14 Mon Sep 17 00:00:00 2001 From: Pedro Algarvio Date: Thu, 20 Feb 2014 12:04:42 +0000 Subject: [PATCH] openSUSE now checks for enabled services --- bootstrap-salt.sh | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/bootstrap-salt.sh b/bootstrap-salt.sh index 70e46c8..bf912f9 100755 --- a/bootstrap-salt.sh +++ b/bootstrap-salt.sh @@ -3208,6 +3208,23 @@ install_opensuse_restart_daemons() { done } + +install_opensuse_check_services() { + if [ ! -f /bin/systemctl ]; then + # Not running systemd!? Don't check! + return 0 + fi + + for fname in minion master syndic; do + # Skip if not meant to be installed + [ $fname = "minion" ] && [ $_INSTALL_MINION -eq $BS_FALSE ] && continue + [ $fname = "master" ] && [ $_INSTALL_MASTER -eq $BS_FALSE ] && continue + [ $fname = "syndic" ] && [ $_INSTALL_SYNDIC -eq $BS_FALSE ] && continue + __check_services_systemd salt-$fname || return 1 + done + return 0 +} + # # End of openSUSE Install Functions. #