By default salt minion meta files are created with wide permissions. This makes OS tokens, keystone credentials unprotected. Patch fixes this. Prod-Related: CEEMCP-13 unprotected keystone credentials Customer-Found Change-Id: I18283cff4aec795e0656b7b3519381792e8a6e54pull/73/head
sh install_salt.sh | sh install_salt.sh | ||||
echo "id: {{ node_name }}.{{ cluster.domain }}" > /etc/salt/minion.d/minion.conf | echo "id: {{ node_name }}.{{ cluster.domain }}" > /etc/salt/minion.d/minion.conf | ||||
echo "master: salt/master: {{ cluster.config.host }}" >> /etc/salt/minion.d/minion.conf | echo "master: salt/master: {{ cluster.config.host }}" >> /etc/salt/minion.d/minion.conf | ||||
service salt-minion restart | |||||
chown root:root /etc/salt/minion.d/minion.conf | |||||
chmod 0600 /etc/salt/minion.d/minion.conf | |||||
service salt-minion restart |
file.managed: | file.managed: | ||||
- source: salt://salt/files/_orchestration.conf | - source: salt://salt/files/_orchestration.conf | ||||
- user: root | - user: root | ||||
- group: root | |||||
- mode: 600 | |||||
- template: jinja | - template: jinja | ||||
- makedirs: true | - makedirs: true | ||||
- require: | - require: |
- source: salt://salt/files/minion.conf | - source: salt://salt/files/minion.conf | ||||
- user: root | - user: root | ||||
- group: root | - group: root | ||||
- mode: 600 | |||||
- template: jinja | - template: jinja | ||||
- require: | - require: | ||||
- {{ minion.install_state }} | - {{ minion.install_state }} | ||||
file.managed: | file.managed: | ||||
- source: salt://salt/files/_renderer.conf | - source: salt://salt/files/_renderer.conf | ||||
- user: root | - user: root | ||||
- group: root | |||||
- mode: 600 | |||||
- template: jinja | - template: jinja | ||||
- require: | - require: | ||||
- {{ minion.install_state }} | - {{ minion.install_state }} |
- source: salt://salt/files/minion.conf | - source: salt://salt/files/minion.conf | ||||
- user: root | - user: root | ||||
- group: root | - group: root | ||||
- mode: 600 | |||||
- template: jinja | - template: jinja | ||||
- require: | - require: | ||||
- {{ minion.install_state }} | - {{ minion.install_state }} | ||||
salt_minion_config_{{ service_name }}_{{ name }}: | salt_minion_config_{{ service_name }}_{{ name }}: | ||||
file.managed: | file.managed: | ||||
- name: /etc/salt/minion.d/_{{ name }}.conf | - name: /etc/salt/minion.d/_{{ name }}.conf | ||||
- user: root | |||||
- group: root | |||||
- mode: 600 | |||||
- contents: | | - contents: | | ||||
{{ conf|yaml(False)|indent(8) }} | {{ conf|yaml(False)|indent(8) }} | ||||
- require: | - require: | ||||
file.managed: | file.managed: | ||||
- source: salt://salt/files/_renderer.conf | - source: salt://salt/files/_renderer.conf | ||||
- user: root | - user: root | ||||
- group: root | |||||
- mode: 600 | |||||
- template: jinja | - template: jinja | ||||
- require: | - require: | ||||
- {{ minion.install_state }} | - {{ minion.install_state }} |