only allow state to run if it is in top for the node

This commit is contained in:
m0duspwnens
2020-09-02 16:15:52 -04:00
parent 870e042c4c
commit a229ae82ce
39 changed files with 274 additions and 10 deletions

View File

@@ -12,6 +12,11 @@
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
{% set show_top = salt['state.show_top']() %}
{% set top_states = show_top.values() | join(', ') %}
{% if 'idstools' in top_states %}
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
{% set MANAGER = salt['grains.get']('master') %}
@@ -69,3 +74,5 @@ so-idstools:
- /opt/so/rules/nids:/opt/so/rules/nids:rw
- watch:
- file: idstoolsetcsync
{% endif%}