enable/disable zeek in ui

This commit is contained in:
m0duspwnens
2023-05-05 16:33:59 -04:00
parent 2a8ed24045
commit a97fa9675b
7 changed files with 319 additions and 297 deletions

16
salt/zeek/sostatus.sls Normal file
View File

@@ -0,0 +1,16 @@
{% from 'allowed_states.map.jinja' import allowed_states %}
{% if sls.split('.')[0] in allowed_states %}
append_so-zeek_so-status.conf:
file.append:
- name: /opt/so/conf/so-status/so-status.conf
- text: so-zeek
- unless: grep -q so-zeek /opt/so/conf/so-status/so-status.conf
{% else %}
{{sls}}_state_not_allowed:
test.fail_without_changes:
- name: {{sls}}_state_not_allowed
{% endif %}