updated saltmaster configuration

This commit is contained in:
Actaeus Curabitur 2022-09-08 06:45:04 -05:00
parent c44f5e30b3
commit e4fe3a92a8
2 changed files with 19 additions and 13 deletions

View file

@ -1,3 +1,4 @@
{%- set os=grains['os'] -%}
salt-master:
{%- if os=="CentOS" or os=="RedHat" %}
pkg.installed: []
@ -17,6 +18,7 @@ salt-master:
- user: root
- group: root
- mode: 644
- template: jinja
/srv/salt/prod/states/pillars:
file.symlink:

View file

@ -422,12 +422,14 @@ state_output: terse
# - /srv/salt/prod/states
#
file_roots:
base:
- /srv/salt/prod/states
prod:
- /srv/salt/prod/states
dev:
- /srv/salt/dev/states
{%- if pillar['branches'] is defined -%}
{%- if pillar['branches']['saltmaster'] is defined -%}
{%- for branch in pillar['branches']['saltmaster'] %}
{{branch}}:
- /srv/salt/{{branch}}/states
{%- endfor %}
{%- endif %}
{%- endif %}
#
# When using multiple environments, each with their own top file, the
@ -439,7 +441,7 @@ file_roots:
# To specify the order in which environments are merged, set the ordering
# in the env_order option. Given a conflict, the last matching value will
# win.
env_order: ['base', 'dev', 'prod']
env_order: ['qual', 'prod']
# If top_file_merging_strategy is set to 'same' and an environment does not
# contain a top file, the top file in the environment specified by default_top
@ -560,12 +562,14 @@ hash_type: sha256
# - /srv/pillar
#
pillar_roots:
base:
- /srv/salt/prod/pillars
prod:
- /srv/salt/prod/pillars
dev:
- /srv/salt/dev/pillars
{%- if pillar['branches'] is defined -%}
{%- if pillar['branches']['saltmaster'] is defined -%}
{%- for branch in pillar['branches']['saltmaster'] %}
{{branch}}:
- /srv/salt/{{branch}}/pillars
{%- endfor %}
{%- endif %}
{%- endif %}
#
#ext_pillar:
# - hiera: /etc/hiera.yaml