https for the ubuntu repo and option to remove /etc/salt/minion.master
# and up as it'll wipe out important files that Salt relies on. | # and up as it'll wipe out important files that Salt relies on. | ||||
clean_config_d_dir: False | clean_config_d_dir: False | ||||
# This state will remove "/etc/salt/minion" when you set this to true. | |||||
minion_remove_config: True | |||||
# This state will remove "/etc/salt/master" when you set this to true. | |||||
master_remove_config: True | |||||
# Set this to False to not have the formula install packages (in the case you | # Set this to False to not have the formula install packages (in the case you | ||||
# install Salt via git/pip/etc.) | # install Salt via git/pip/etc.) | ||||
install_packages: True | install_packages: True | ||||
# salt cloud config | # salt cloud config | ||||
cloud: | cloud: | ||||
master: salt | master: salt | ||||
# For non-templated custom cloud provider/profile/map files | # For non-templated custom cloud provider/profile/map files | ||||
providers: | providers: | ||||
provider-filename1.conf: | provider-filename1.conf: | ||||
map-filename1.map: | map-filename1.map: | ||||
server-non-prod: | server-non-prod: | ||||
- host.mycompany.com: | - host.mycompany.com: | ||||
grains: | |||||
grains: | |||||
environment: dev1 | environment: dev1 | ||||
# You can take profile and map templates from an alternate location | # You can take profile and map templates from an alternate location |
config_path: /etc/salt | config_path: /etc/salt | ||||
minion_remove_config: False | |||||
master_remove_config: False | |||||
minion_service: salt-minion | minion_service: salt-minion | ||||
master_service: salt-master | master_service: salt-master | ||||
api_service: salt-api | api_service: salt-api |
- file: salt-master | - file: salt-master | ||||
- file: remove-old-master-conf-file | - file: remove-old-master-conf-file | ||||
{% if salt_settings.master_remove_config %} | |||||
remove-default-master-conf-file: | |||||
file.absent: | |||||
- name: {{ salt_settings.config_path }}/master | |||||
{% endif %} | |||||
# clean up old _defaults.conf file if they have it around | # clean up old _defaults.conf file if they have it around | ||||
remove-old-master-conf-file: | remove-old-master-conf-file: | ||||
file.absent: | file.absent: |
- file: salt-minion | - file: salt-minion | ||||
- file: remove-old-minion-conf-file | - file: remove-old-minion-conf-file | ||||
{% if salt_settings.minion_remove_config %} | |||||
remove-default-minion-conf-file: | |||||
file.absent: | |||||
- name: {{ salt_settings.config_path }}/minion | |||||
{% endif %} | |||||
# clean up old _defaults.conf file if they have it around | # clean up old _defaults.conf file if they have it around | ||||
remove-old-minion-conf-file: | remove-old-minion-conf-file: | ||||
file.absent: | file.absent: |
saltstack-pkgrepo: | saltstack-pkgrepo: | ||||
pkgrepo.managed: | pkgrepo.managed: | ||||
- name: deb http://repo.saltstack.com/apt/ubuntu/{{ grains['lsb_distrib_release'] }}/amd64/latest {{ grains['lsb_distrib_codename'] }} main | |||||
- name: deb https://repo.saltstack.com/apt/ubuntu/{{ grains['lsb_distrib_release'] }}/amd64/latest {{ grains['lsb_distrib_codename'] }} main | |||||
- file: /etc/apt/sources.list.d/saltstack.list | - file: /etc/apt/sources.list.d/saltstack.list | ||||
- key_url: https://repo.saltstack.com/apt/ubuntu/{{ grains['lsb_distrib_release'] }}/amd64/latest/SALTSTACK-GPG-KEY.pub | - key_url: https://repo.saltstack.com/apt/ubuntu/{{ grains['lsb_distrib_release'] }}/amd64/latest/SALTSTACK-GPG-KEY.pub |