From ee1f55361ed32213e92aa2fb28f6c4bb2be451ff Mon Sep 17 00:00:00 2001 From: Mike Reeves Date: Mon, 31 Oct 2022 16:33:38 -0400 Subject: [PATCH 1/2] Add soup and perms updates --- salt/common/tools/sbin/soup | 13 +++++++++++++ salt/zeek/init.sls | 2 ++ 2 files changed, 15 insertions(+) diff --git a/salt/common/tools/sbin/soup b/salt/common/tools/sbin/soup index c96d4e904..54266ca84 100755 --- a/salt/common/tools/sbin/soup +++ b/salt/common/tools/sbin/soup @@ -549,6 +549,7 @@ preupgrade_changes() { [[ "$INSTALLEDVERSION" == 2.3.160 ]] && up_to_2.3.170 [[ "$INSTALLEDVERSION" == 2.3.170 ]] && up_to_2.3.180 [[ "$INSTALLEDVERSION" == 2.3.180 ]] && up_to_2.3.181 + [[ "$INSTALLEDVERSION" == 2.3.181 ]] && up_to_2.3.190 true } @@ -570,6 +571,7 @@ postupgrade_changes() { [[ "$POSTVERSION" == 2.3.160 ]] && post_to_2.3.170 [[ "$POSTVERSION" == 2.3.170 ]] && post_to_2.3.180 [[ "$POSTVERSION" == 2.3.180 ]] && post_to_2.3.181 + [[ "$POSTVERSION" == 2.3.181 ]] && post_to_2.3.190 true } @@ -673,6 +675,10 @@ post_to_2.3.181() { echo "Nothing to do for .181" } +post_to_2.3.190() { + echo "Nothing to do for .190" +} + stop_salt_master() { # kill all salt jobs across the grid because the hang indefinitely if they are queued and salt-master restarts set +e @@ -972,6 +978,13 @@ up_to_2.3.181() { INSTALLEDVERSION=2.3.181 } +up_to_2.3.190() { + echo "Upgrading to 2.3.190" + chown -R zeek:socore /nsm/zeek/extracted/complete + chmod 770 /nsm/zeek/extracted/complete + INSTALLEDVERSION=2.3.190 +} + verify_upgradespace() { CURRENTSPACE=$(df -BG / | grep -v Avail | awk '{print $4}' | sed 's/.$//') if [ "$CURRENTSPACE" -lt "10" ]; then diff --git a/salt/zeek/init.sls b/salt/zeek/init.sls index 4640f0fea..dda1bed52 100644 --- a/salt/zeek/init.sls +++ b/salt/zeek/init.sls @@ -70,6 +70,7 @@ zeekextractdir: - name: /nsm/zeek/extracted - user: 937 - group: 939 + - mode: 770 - makedirs: True zeekextractcompletedir: @@ -77,6 +78,7 @@ zeekextractcompletedir: - name: /nsm/zeek/extracted/complete - user: 937 - group: 939 + - mode: 770 - makedirs: True # Sync the policies From 16d8e9e5a01bc9983708809898bdfd6aa19a261d Mon Sep 17 00:00:00 2001 From: Mike Reeves Date: Tue, 1 Nov 2022 09:05:26 -0400 Subject: [PATCH 2/2] Fix soup and perms updates --- salt/common/tools/sbin/soup | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/salt/common/tools/sbin/soup b/salt/common/tools/sbin/soup index 54266ca84..2edbcd35c 100755 --- a/salt/common/tools/sbin/soup +++ b/salt/common/tools/sbin/soup @@ -657,26 +657,32 @@ post_to_2.3.140() { post_to_2.3.150() { echo "Nothing to do for .150" + POSTVERSION=2.3.150 } post_to_2.3.160() { echo "Nothing to do for .160" + POSTVERSION=2.3.160 } post_to_2.3.170() { echo "Nothing to do for .170" + POSTVERSION=2.3.170 } post_to_2.3.180() { echo "Nothing to do for .180" + POSTVERSION=2.3.180 } post_to_2.3.181() { echo "Nothing to do for .181" + POSTVERSION=2.3.181 } post_to_2.3.190() { echo "Nothing to do for .190" + POSTVERSION=2.3.190 } stop_salt_master() {