salt/states/top.sls

42 lines
1 KiB
Text
Raw Permalink Normal View History

2017-08-07 13:25:01 -05:00
{%- set states = salt['cp.list_states'](saltenv) -%}
2022-09-22 11:05:24 -05:00
{% for env in pillar['envs'] %}
2017-08-07 13:25:01 -05:00
{{ env }}:
'os_family:RedHat':
2017-08-07 13:25:01 -05:00
- match: grain_pcre
- repos.epel
'os_family:Arch':
2017-08-07 13:25:01 -05:00
- match: grain_pcre
2023-09-21 21:54:05 -05:00
- repos.arch
2017-08-07 13:25:01 -05:00
- systems.arch.mirrors
- systems.core.freeipa
2017-08-07 13:25:01 -05:00
'*':
{#- don't run update automatically on containers - updates will be triggered from their host -#}
{%- if pillar['roles'] is defined -%}
{%- if 'lxc_container' not in pillar['roles'] %}
2017-08-07 13:25:01 -05:00
- update
{%- endif -%}
{%- endif %}
- update.clean_cache
- update.update_containers
2017-08-07 13:25:01 -05:00
- basepkgs
- grains
- bashrc
2017-08-07 13:25:01 -05:00
- systems.core.firewalld
- systems.core.monitoring
2017-08-07 13:25:01 -05:00
- systems.core.mount
- systems.core.git
- systems.core.backup
2022-11-15 15:56:18 -06:00
- systems.core.time
{%- if pillar['roles'] is defined -%}
{%- if pillar['roles'] is not none -%}
{%- for role in pillar['roles'] %}
2017-08-07 13:25:01 -05:00
{%- if 'roles.maintain.'+role in states %}
- roles.maintain.{{role}}
{%- endif -%}
{%- endfor -%}
{%- endif -%}
{%- endif -%}
{%- endfor %}
2022-08-17 09:20:26 -05:00
- systems.core.fstrim