|
-
- {%- load_yaml as master_common %}
- default:
- service: salt-master
- {%- if pillar.salt.master is defined %}
- {%- if pillar.salt.master.source.engine == 'pkg' %}
- install_state: "pkg: salt_master_packages"
- {%- elif pillar.salt.master.source.engine == 'pip' %}
- install_state: "pip: salt_master_packages"
- {%- endif %}
- {%- endif %}
- {%- if pillar.salt.master.source.version is defined %}
- version: {{ pillar.salt.master.source.version }}
- {%- endif %}
- accept_policy: preseed
- bind: {}
- formula: {}
- base_environment: dev
- dir:
- files: /srv/salt/env
- pillar:
- engine: salt
- {%- endload %}
-
- {%- load_yaml as master_specific %}
- Arch:
- pkgs:
- - salt-zmq
- Debian:
- pkgs:
- - salt-master
- Gentoo:
- pkgs:
- - app-admin/salt
- MacOS:
- pkgs:
- - saltstack
- RedHat:
- pkgs:
- - salt-master
- {%- endload %}
-
- {%- set raw_master = salt['grains.filter_by'](master_specific, merge=salt['pillar.get']('salt:master')) %}
- {%- set master = salt['grains.filter_by'](master_common, merge=raw_master) %}
-
-
- {%- load_yaml as minion_common %}
- default:
- graph_pkgs:
- - graphviz
- graph_states_pkgs:
- - python-pydot
- - python-yaml
- graph_states: False
- service: salt-minion
- {%- if pillar.salt.minion is defined %}
- {%- if pillar.salt.minion.source.engine == 'pkg' %}
- install_state: "pkg: salt_minion_packages"
- {%- elif pillar.salt.minion.source.engine == 'pip' %}
- install_state: "pip: salt_minion_packages"
- {%- endif %}
- {%- endif %}
- {%- if pillar.salt.minion.source.version is defined %}
- version: {{ pillar.salt.minion.source.version }}
- {%- endif %}
- {%- endload %}
-
- {%- load_yaml as minion_specific %}
- Arch:
- pkgs:
- - salt-zmq
- Debian:
- pkgs:
- - salt-minion
- Gentoo:
- pkgs:
- - app-admin/salt
- MacOS:
- pkgs:
- - saltstack
- RedHat:
- pkgs:
- - salt-minion
- {%- endload %}
-
- {%- set raw_minion = salt['grains.filter_by'](minion_specific, merge=salt['pillar.get']('salt:minion')) %}
- {%- set minion = salt['grains.filter_by'](minion_common, merge=raw_minion) %}
-
-
- {%- load_yaml as api_common %}
- default:
- pkgs:
- - salt-api
- service: salt-api
- {%- endload %}
-
- {%- set api = salt['grains.filter_by'](api_common, merge=salt['pillar.get']('salt:api')) %}
-
- {%- load_yaml as control_common %}
- default:
- cloud_pips:
- - apache-libcloud
- - netaddr
- cloud_pkgs:
- - python-netaddr
- - python-libcloud
- virt_pips:
- - libvirt-python
- maas_pkgs:
- - python-maas-client
- cluster: {}
- {%- endload %}
-
- {%- load_yaml as control_specific %}
- Debian:
- virt_pkgs:
- - libvirt-dev
- - pkg-config
- - libguestfs-tools
- RedHat:
- virt_pkgs:
- - libvirt-dev
- - pkg-config
- {%- endload %}
-
- {%- set raw_control = salt['grains.filter_by'](control_specific, merge=salt['pillar.get']('salt:control')) %}
- {%- set control = salt['grains.filter_by'](control_common, merge=raw_control) %}
|