-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathkubeadm_deploy_step5.txt
42 lines (37 loc) · 2.48 KB
/
kubeadm_deploy_step5.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
kubeadm alpha phase certs etcd-server --config=/tmp/${zoo5}/kubeadmcfg.yaml
kubeadm alpha phase certs etcd-peer --config=/tmp/${zoo5}/kubeadmcfg.yaml
kubeadm alpha phase certs etcd-healthcheck-client --config=/tmp/${zoo5}/kubeadmcfg.yaml
kubeadm alpha phase certs apiserver-etcd-client --config=/tmp/${zoo5}/kubeadmcfg.yaml
cp -R /etc/kubernetes/pki /tmp/${zoo5}/
# cleanup non-reusable certificates
find /etc/kubernetes/pki -not -name ca.crt -not -name ca.key -type f -delete
kubeadm alpha phase certs etcd-server --config=/tmp/${zoo4}/kubeadmcfg.yaml
kubeadm alpha phase certs etcd-peer --config=/tmp/${zoo4}/kubeadmcfg.yaml
kubeadm alpha phase certs etcd-healthcheck-client --config=/tmp/${zoo4}/kubeadmcfg.yaml
kubeadm alpha phase certs apiserver-etcd-client --config=/tmp/${zoo4}/kubeadmcfg.yaml
cp -R /etc/kubernetes/pki /tmp/${zoo4}/
# cleanup non-reusable certificates
find /etc/kubernetes/pki -not -name ca.crt -not -name ca.key -type f -delete
kubeadm alpha phase certs etcd-server --config=/tmp/${zoo3}/kubeadmcfg.yaml
kubeadm alpha phase certs etcd-peer --config=/tmp/${zoo3}/kubeadmcfg.yaml
kubeadm alpha phase certs etcd-healthcheck-client --config=/tmp/${zoo3}/kubeadmcfg.yaml
kubeadm alpha phase certs apiserver-etcd-client --config=/tmp/${zoo3}/kubeadmcfg.yaml
cp -R /etc/kubernetes/pki /tmp/${zoo3}/
# cleanup non-reusable certificates
find /etc/kubernetes/pki -not -name ca.crt -not -name ca.key -type f -delete
kubeadm alpha phase certs etcd-server --config=/tmp/${zoo2}/kubeadmcfg.yaml
kubeadm alpha phase certs etcd-peer --config=/tmp/${zoo2}/kubeadmcfg.yaml
kubeadm alpha phase certs etcd-healthcheck-client --config=/tmp/${zoo2}/kubeadmcfg.yaml
kubeadm alpha phase certs apiserver-etcd-client --config=/tmp/${zoo2}/kubeadmcfg.yaml
cp -R /etc/kubernetes/pki /tmp/${zoo2}/
find /etc/kubernetes/pki -not -name ca.crt -not -name ca.key -type f -delete
kubeadm alpha phase certs etcd-server --config=/tmp/${zoo1}/kubeadmcfg.yaml
kubeadm alpha phase certs etcd-peer --config=/tmp/${zoo1}/kubeadmcfg.yaml
kubeadm alpha phase certs etcd-healthcheck-client --config=/tmp/${zoo1}/kubeadmcfg.yaml
kubeadm alpha phase certs apiserver-etcd-client --config=/tmp/${zoo1}/kubeadmcfg.yaml
# No need to move the certs because they are for zoo1
# clean up certs that should not be copied off this host
find /tmp/${zoo5} -name ca.key -type f -delete
find /tmp/${zoo4} -name ca.key -type f -delete
find /tmp/${zoo3} -name ca.key -type f -delete
find /tmp/${zoo2} -name ca.key -type f -delete