From df0a774ffd96191ef5f20457ea5a88ccc8c16964 Mon Sep 17 00:00:00 2001 From: Mike Reeves Date: Tue, 5 Jul 2022 16:17:32 -0400 Subject: [PATCH] Make soup enforce versions --- salt/common/tools/sbin/soup | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/salt/common/tools/sbin/soup b/salt/common/tools/sbin/soup index 9e21af55f..b5f6f5b32 100755 --- a/salt/common/tools/sbin/soup +++ b/salt/common/tools/sbin/soup @@ -377,6 +377,18 @@ enable_highstate() { echo "" } +es_version_check() { + CHECK_ES=$(echo $INSTALLEDVERSION | aek -F. '{print $3}' + if [ "$CHECK_ES" -lt "110" ]; then + echo "In order to update to the latest version of Security Onion you need to at least be on version 2.3.110. We recommend installing 2.3.130." + echo "" + echo "To install 2.3.130 via the internet use the following command:" + echo "sudo BRANCH=2.3.130-20220607 soup" + echo "If you are an airgap userplease download 2.3.130 from https://download.securityonion.net/file/securityonion/securityonion-2.3.130-20220607.iso" + echo "*** YOU WILL NEED TO RUN THE SOUP COMMAND TWICE! ***" + exit 0 +} + generate_and_clean_tarballs() { local new_version new_version=$(cat $UPDATE_DIR/VERSION) @@ -1081,6 +1093,7 @@ main() { echo "" set_os + es_version_check set_cron_service_name if ! check_salt_master_status; then echo "Could not talk to salt master"