mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2026-02-28 09:39:12 +03:00
Calculate etcd client cert serial for appropriate groups (#3605)
Standalone etcd nodes do not generate node-$hostname certs and do not need this serial calculated.
This commit is contained in:
committed by
k8s-ci-robot
parent
0cb326b10f
commit
bc74a37696
@@ -17,7 +17,8 @@
|
|||||||
command: "openssl x509 -in {{ etcd_cert_dir }}/node-{{ inventory_hostname }}.pem -noout -serial"
|
command: "openssl x509 -in {{ etcd_cert_dir }}/node-{{ inventory_hostname }}.pem -noout -serial"
|
||||||
register: "etcd_client_cert_serial_result"
|
register: "etcd_client_cert_serial_result"
|
||||||
changed_when: false
|
changed_when: false
|
||||||
when: inventory_hostname in groups['k8s-cluster']|union(groups['etcd'])|union(groups['calico-rr']|default([]))|unique|sort
|
when:
|
||||||
|
- inventory_hostname in groups['k8s-cluster']|union(groups['calico-rr']|default([]))|unique|sort
|
||||||
tags:
|
tags:
|
||||||
- master
|
- master
|
||||||
- network
|
- network
|
||||||
@@ -25,7 +26,8 @@
|
|||||||
- name: Set etcd_client_cert_serial
|
- name: Set etcd_client_cert_serial
|
||||||
set_fact:
|
set_fact:
|
||||||
etcd_client_cert_serial: "{{ etcd_client_cert_serial_result.stdout.split('=')[1] }}"
|
etcd_client_cert_serial: "{{ etcd_client_cert_serial_result.stdout.split('=')[1] }}"
|
||||||
when: inventory_hostname in groups['k8s-cluster']|union(groups['etcd'])|union(groups['calico-rr']|default([]))|unique|sort
|
when:
|
||||||
|
- inventory_hostname in groups['k8s-cluster']|union(groups['calico-rr']|default([]))|unique|sort
|
||||||
tags:
|
tags:
|
||||||
- master
|
- master
|
||||||
- network
|
- network
|
||||||
|
|||||||
Reference in New Issue
Block a user