mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2026-05-22 00:07:45 -02:30
Use find module for checking for certificates
Also generate certs only when absent on master (rather than when absent on target node)
This commit is contained in:
@@ -40,12 +40,12 @@
|
||||
command: "{{ kube_script_dir }}/make-ssl.sh -f {{ kube_config_dir }}/openssl.conf -d {{ kube_cert_dir }}"
|
||||
environment:
|
||||
- MASTERS: "{% for m in groups['kube-master'] %}
|
||||
{% if hostvars[m].sync_certs|default(true) %}
|
||||
{% if gen_node_certs[m]|default(false) %}
|
||||
{{ m }}
|
||||
{% endif %}
|
||||
{% endfor %}"
|
||||
- HOSTS: "{% for h in groups['k8s-cluster'] %}
|
||||
{% if hostvars[h].sync_certs|default(true) %}
|
||||
{% if gen_node_certs[h]|default(true) %}
|
||||
{{ h }}
|
||||
{% endif %}
|
||||
{% endfor %}"
|
||||
|
||||
Reference in New Issue
Block a user