Skip to content
Snippets Groups Projects
Commit 9f8466a1 authored by Spencer Smith's avatar Spencer Smith
Browse files

ensure ALL certs are synced between masters

parent 5253b3ec
No related branches found
No related tags found
No related merge requests found
......@@ -21,7 +21,7 @@
notify: set secret_changed
- set_fact:
master_certs: ['ca.pem', 'ca-key.pem', 'admin.pem', 'admin-key.pem', 'apiserver-key.pem', 'apiserver.pem']
master_certs: ['ca-key.pem', 'admin.pem', 'admin-key.pem', 'apiserver-key.pem', 'apiserver.pem']
node_certs: ['ca.pem', 'node.pem', 'node-key.pem']
- name: certs | Get the certs from first master
......@@ -39,8 +39,7 @@
content: "{{ item.content|b64decode }}"
dest: "{{ item.source }}"
with_items: '{{slurp_certs.results}}'
when: item.item in master_certs and
inventory_hostname in groups['kube-master'] and sync_certs|default(false) and
when: inventory_hostname in groups['kube-master'] and sync_certs|default(false) and
inventory_hostname != groups['kube-master'][0]
- name: certs | Copy certs on nodes
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment