mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-06 17:22:49 +01:00
if deb fam, stop salt-master and salt-minion after salt upgrade
This commit is contained in:
@@ -453,7 +453,7 @@ wait_for_salt_minion() {
|
|||||||
local maxAttempts=20
|
local maxAttempts=20
|
||||||
until check_salt_minion_status "$minion" "$timeout" "$logfile"; do
|
until check_salt_minion_status "$minion" "$timeout" "$logfile"; do
|
||||||
attempt=$((attempt+1))
|
attempt=$((attempt+1))
|
||||||
if [[ $attempt -gt $maxAttempts ]]; then
|
if [[ $attempt -eq $maxAttempts ]]; then
|
||||||
return 1
|
return 1
|
||||||
fi
|
fi
|
||||||
sleep 10
|
sleep 10
|
||||||
|
|||||||
@@ -866,6 +866,16 @@ main() {
|
|||||||
echo "Upgrading Salt"
|
echo "Upgrading Salt"
|
||||||
# Update the repo files so it can actually upgrade
|
# Update the repo files so it can actually upgrade
|
||||||
upgrade_salt
|
upgrade_salt
|
||||||
|
|
||||||
|
# for Debian based distro, we need to stop salt again after upgrade output below is from bootstrap-salt
|
||||||
|
# * WARN: Not starting daemons on Debian based distributions
|
||||||
|
# is not working mostly because starting them is the default behaviour.
|
||||||
|
if [[ $is_deb ]]; then
|
||||||
|
systemctl status salt-master
|
||||||
|
systemctl status salt-minion
|
||||||
|
stop_salt_master
|
||||||
|
stop_salt_minion
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
preupgrade_changes
|
preupgrade_changes
|
||||||
|
|||||||
Reference in New Issue
Block a user