Skip to content
Snippets Groups Projects
Unverified Commit 411510cb authored by jeanfabrice's avatar jeanfabrice Committed by GitHub
Browse files

Use proper openssl command to differentiate between host and ip in API certificate check (#6392)

* Use proper openssl command to differentiate between host and ip in current certificate check

* fixup! Use proper openssl command to differentiate between host and ip in current certificate check
parent 6e2b8a57
No related branches found
No related tags found
No related merge requests found
......@@ -112,7 +112,7 @@
- kubeadm_already_run.stat.exists
- name: kubeadm | Check if apiserver.crt contains all needed SANs
command: openssl x509 -noout -in "{{ kube_cert_dir }}/apiserver.crt" -checkip "{{ item }}"
command: openssl x509 -noout -in "{{ kube_cert_dir }}/apiserver.crt" -check{{ item|ipaddr|ternary('ip','host') }} "{{ item }}"
with_items: "{{ apiserver_sans }}"
register: apiserver_sans_check
changed_when: "'does match certificate' not in apiserver_sans_check.stdout"
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment