diff --git a/salt/manager/tools/sbin/soup b/salt/manager/tools/sbin/soup index c592dffe4..2cd108d00 100755 --- a/salt/manager/tools/sbin/soup +++ b/salt/manager/tools/sbin/soup @@ -404,6 +404,7 @@ preupgrade_changes() { [[ "$INSTALLEDVERSION" == 2.4.80 ]] && up_to_2.4.90 [[ "$INSTALLEDVERSION" == 2.4.90 ]] && up_to_2.4.100 [[ "$INSTALLEDVERSION" == 2.4.100 ]] && up_to_2.4.110 + [[ "$INSTALLEDVERSION" == 2.4.110 ]] && up_to_2.4.120 true } @@ -425,6 +426,7 @@ postupgrade_changes() { [[ "$POSTVERSION" == 2.4.80 ]] && post_to_2.4.90 [[ "$POSTVERSION" == 2.4.90 ]] && post_to_2.4.100 [[ "$POSTVERSION" == 2.4.100 ]] && post_to_2.4.110 + [[ "$POSTVERSION" == 2.4.110 ]] && post_to_2.4.120 true } @@ -517,6 +519,11 @@ post_to_2.4.110() { POSTVERSION=2.4.110 } +post_to_2.4.120() { + echo "Nothing to apply" + POSTVERSION=2.4.120 +} + repo_sync() { echo "Sync the local repo." su socore -c '/usr/sbin/so-repo-sync' || fail "Unable to complete so-repo-sync." @@ -705,6 +712,29 @@ up_to_2.4.110() { INSTALLEDVERSION=2.4.110 } +up_to_2.4.120() { + echo "Nothing to do for 2.4.120" + + add_hydra_pillars + + INSTALLEDVERSION=2.4.120 +} + +add_hydra_pillars() { + mkdir -p /opt/so/saltstack/local/pillar/hydra + touch /opt/so/saltstack/local/pillar/hydra/soc_hydra.sls + chmod 660 /opt/so/saltstack/local/pillar/hydra/soc_hydra.sls + touch /opt/so/saltstack/local/pillar/hydra/adv_hydra.sls + HYDRAKEY=$(get_random_value) + printf '%s\n'\ + "hydra:"\ + " config:"\ + " secrets:"\ + " system:"\ + " - '$HYDRAKEY'"\ + "" > /opt/so/saltstack/local/pillar/hydra/soc_hydra.sls +} + add_detection_test_pillars() { if [[ -n "$SOUP_INTERNAL_TESTING" ]]; then echo "Adding detection pillar values for automated testing"