forked from kubernetes-sigs/kubespray
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Always backup both certs and kubeconfig
There are no reasons not to backup during upgrade Signed-off-by: Etienne Champetier <[email protected]>
- Loading branch information
1 parent
8800b5c
commit 53e5ef6
Showing
3 changed files
with
33 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
--- | ||
- name: Backup old certs and keys | ||
copy: | ||
src: "{{ kube_cert_dir }}/{{ item }}" | ||
dest: "{{ kube_cert_dir }}/{{ item }}.old" | ||
mode: preserve | ||
remote_src: yes | ||
with_items: | ||
- apiserver.crt | ||
- apiserver.key | ||
- apiserver-kubelet-client.crt | ||
- apiserver-kubelet-client.key | ||
- front-proxy-client.crt | ||
- front-proxy-client.key | ||
ignore_errors: yes | ||
|
||
- name: Backup old confs | ||
copy: | ||
src: "{{ kube_config_dir }}/{{ item }}" | ||
dest: "{{ kube_config_dir }}/{{ item }}.old" | ||
mode: preserve | ||
remote_src: yes | ||
with_items: | ||
- admin.conf | ||
- controller-manager.conf | ||
- kubelet.conf | ||
- scheduler.conf | ||
ignore_errors: yes |
15 changes: 0 additions & 15 deletions
15
roles/kubernetes/control-plane/tasks/kubeadm-certificate.yml
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters