diff --git a/salt/common/tools/sbin/soup b/salt/common/tools/sbin/soup index dc10b3f18..dd8cf7b3f 100755 --- a/salt/common/tools/sbin/soup +++ b/salt/common/tools/sbin/soup @@ -1159,6 +1159,7 @@ main() { if [[ $is_airgap -eq 0 ]]; then echo "" echo "Cleaning repos on remote Security Onion nodes." + salt -C 'not *_eval and not *_helixsensor and not *_manager and not *_managersearch and not *_standalone and G@os:CentOS' state.apply repo.client -l info salt -C 'not *_eval and not *_helixsensor and not *_manager and not *_managersearch and not *_standalone and G@os:CentOS' cmd.run "yum clean all" echo "" fi diff --git a/salt/repo/client/init.sls b/salt/repo/client/init.sls index 739b839d3..081fef762 100644 --- a/salt/repo/client/init.sls +++ b/salt/repo/client/init.sls @@ -47,6 +47,12 @@ crsynckeys: - source: salt://repo/client/files/centos/keys/ {% if not ISAIRGAP %} + {% if role in ['eval', 'standalone', 'import', 'manager', 'managersearch'] or managerupdates == 0 %} +remove_securityonionrepocache: + file.absent: + - name: /etc/yum.repos.d/securityonioncache.repo + {% endif %} + crsecurityonionrepo: file.managed: {% if role in ['eval', 'standalone', 'import', 'manager', 'managersearch'] or managerupdates == 0 %}