From da94788255407268b2edbfcae0894e20d185b7bd Mon Sep 17 00:00:00 2001 From: Josh Patterson Date: Fri, 26 Jun 2026 10:51:41 -0400 Subject: [PATCH] Move highstate_interval_hours to salt.schedule and split schedule.sls highstate_interval_hours describes the per-minion highstate schedule, not the active-push pipeline, so relocate it from salt.auto_apply to a new salt.schedule settings subtree. Repoint so-salt-minion-check at the new pillar path (it had been left on the stale global:push path) so its restart grace period tracks the schedule again. - Add salt.schedule.highstate_interval_hours to defaults.yaml/soc_salt.yaml and a side-effect-free salt/salt/schedule.map.jinja (SCHEDULEMERGED), matching the *MERGED map convention. Consumers read SCHEDULEMERGED.highstate_interval_hours. - Split salt/schedule.sls into salt/salt/highstate_schedule.sls (every minion) and salt/salt/push_drain_schedule.sls (managers); update top.sls to apply the highstate schedule via '*' and the drainer schedule via the configured-manager block. Remove the now-empty schedule.sls aggregator. - pillar_push_map.yaml and so-push-drainer: comment/doc updates only. --- salt/common/tools/sbin_jinja/so-salt-minion-check | 6 +++--- salt/manager/tools/sbin/so-push-drainer | 2 +- salt/reactor/pillar_push_map.yaml | 12 ++++++------ salt/salt/defaults.yaml | 3 ++- salt/salt/highstate_schedule.sls | 11 +++++++++++ salt/{schedule.sls => salt/push_drain_schedule.sls} | 9 --------- salt/salt/schedule.map.jinja | 2 ++ salt/salt/soc_salt.yaml | 13 +++++++------ salt/top.sls | 4 ++-- 9 files changed, 34 insertions(+), 28 deletions(-) create mode 100644 salt/salt/highstate_schedule.sls rename salt/{schedule.sls => salt/push_drain_schedule.sls} (69%) create mode 100644 salt/salt/schedule.map.jinja diff --git a/salt/common/tools/sbin_jinja/so-salt-minion-check b/salt/common/tools/sbin_jinja/so-salt-minion-check index 3b2b32afe..1376193cc 100755 --- a/salt/common/tools/sbin_jinja/so-salt-minion-check +++ b/salt/common/tools/sbin_jinja/so-salt-minion-check @@ -5,7 +5,7 @@ # https://securityonion.net/license; you may not use this file except in compliance with the # Elastic License 2.0. - +{% from 'salt/schedule.map.jinja' import SCHEDULEMERGED %} # this script checks the time the file /opt/so/log/salt/state-apply-test was last modified and restarts the salt-minion service if it is outside a threshold date/time # the file is modified via file.touch using a scheduled job healthcheck.salt-minion.state-apply-test that runs a state.apply. @@ -23,8 +23,8 @@ SYSTEM_START_TIME=$(date -d "$(