Fix etcd install with docker and etcd_kubeadm_enabled (#5777)

- This solves issue #5721 & #5713 (dupes)
  - Provide a cleaner default usage pattern for the download role
    around etcd that supports 'host' and 'docker' properly
  - Extract the 'etcdctl' as a separate task install piece and reuse it where
    appropriate
  - Update the kubeadm-etcd task to reflect the above change
This commit is contained in:
Stephen Schmidt
2020-03-24 11:12:47 -04:00
committed by GitHub
parent bc2eeb0560
commit 0379a52f03
6 changed files with 31 additions and 15 deletions

View File

@@ -540,17 +540,17 @@ downloads:
etcd:
container: "{{ etcd_deployment_type != 'host' }}"
file: "{{ etcd_deployment_type == 'host' or etcd_kubeadm_enabled }}"
file: "{{ etcd_deployment_type == 'host' }}"
enabled: true
version: "{{ etcd_version }}"
dest: "{{local_release_dir}}/etcd-{{ etcd_version }}-linux-amd64.tar.gz"
dest: "{{ local_release_dir }}/etcd-{{ etcd_version }}-linux-amd64.tar.gz"
repo: "{{ etcd_image_repo }}"
tag: "{{ etcd_image_tag }}"
sha256: >-
{{ etcd_binary_checksum if (etcd_deployment_type == 'host' or etcd_kubeadm_enabled)
{{ etcd_binary_checksum if (etcd_deployment_type == 'host')
else etcd_digest_checksum|d(None) }}
url: "{{ etcd_download_url }}"
unarchive: true
unarchive: "{{ etcd_deployment_type == 'host' }}"
owner: "root"
mode: "0755"
groups: