mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-06 17:22:49 +01:00
check if service is running before trying to start it
This commit is contained in:
@@ -1081,9 +1081,12 @@ apply_hotfix() {
|
||||
}
|
||||
|
||||
failed_soup_restore_items() {
|
||||
systemctl_func "start" "$cron_service_name"
|
||||
systemctl_func "start" "salt-master"
|
||||
systemctl_func "start" "salt-minion"
|
||||
local services=("$cron_service_name", "salt-master", "salt-minion")
|
||||
for SERVICE_NAME in "${services[@]}"; do
|
||||
if ! systemctl is-active --quiet "$SERVICE_NAME"; then
|
||||
systemctl_func "start" "$SERVICE_NAME"
|
||||
fi
|
||||
done
|
||||
enable_highstate
|
||||
masterunlock
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user