|
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788 |
- {%- from "salt/map.jinja" import master with context %}
- {%- from "linux/map.jinja" import system with context %}
-
- worker_threads: {{ master.worker_threads }}
- timeout: {{ master.command_timeout }}
-
- state_output: {{ master.get('state_output', 'changes') }}
-
- {%- if master.system is defined %}
-
- file_roots:
- base:
- - {{ master.dir.files }}/{{ master.system.environment }}
- {%- for formula_name, formula in master.system.get('formula', {}).iteritems() %}
- - {{ master.dir.files }}/{{ master.system.environment }}/{{ formula_name }}
- {%- endfor %}
- {{ master.system.environment }}:
- - {{ master.dir.files }}/{{ master.system.environment }}
- {%- for formula_name, formula in master.system.get('formula', {}).iteritems() %}
- - {{ master.dir.files }}/{{ master.system.environment }}/{{ formula_name }}
- {%- endfor %}
-
- {%- else %}
-
- file_roots:
- {%- for environment_name, environment in master.get('environment', {}).iteritems() %}
- {%- if master.base_environment == environment_name %}
- base:
- - {{ master.dir.files }}/{{ environment_name }}
- {%- endif %}
- {{ environment_name }}:
- - {{ master.dir.files }}/{{ environment_name }}
- {%- endfor %}
-
- {%- endif %}
-
- pillar_opts: False
-
- {%- if master.accept_policy == 'open_mode' %}
- open_mode: True
- {%- endif %}
-
- {%- if master.accept_policy == 'auto_accept' %}
- auto_accept: True
- {%- endif %}
-
- {%- if master.pillar.engine == 'salt' %}
-
- pillar_roots:
- base:
- - /srv/salt/pillar
-
- {%- endif %}
-
- {%- if master.pillar.engine == 'reclass' %}
-
- reclass: &reclass
- storage_type: yaml_fs
- inventory_base_uri: /srv/salt/reclass
-
- ext_pillar:
- - reclass: *reclass
-
- master_tops:
- reclass: *reclass
-
- {%- endif %}
-
- {%- for handler in pillar.salt.minion.get("handlers", []) %}
-
- {%- if handler.engine == "udp"%}
- logstash_udp_handler:
- host: {{ handler.host }}
- port: {{ handler.port }}
- version: 1
- {%- endif %}
-
- {%- if handler.engine == "zmq"%}
- logstash_zmq_handler:
- address: tcp://{{ handler.host }}:{{ handler.port }}
- version: 1
- {%- endif %}
-
- {%- endfor %}
-
- {%- if master.get('order_masters', False) %}
- order_masters: True
- {%- endif %}
|