Fix crictl paths and some of docker paths (#6961)

If crictl (and docker) binaries are deployed to the directories
that are not in standard PATH (e.g. /usr/local/bin), it is required
to specify full path to the binaries.
This commit is contained in:
Alexander D. Kanevskiy
2020-11-28 18:30:47 +02:00
committed by GitHub
parent c6f6940459
commit d4204a42fd
6 changed files with 21 additions and 21 deletions

View File

@@ -32,11 +32,11 @@
- block:
- name: Copy etcdctl script to host
shell: "docker exec \"$(docker ps -qf ancestor={{ etcd_image_repo }}:{{ etcd_image_tag }})\" cp /usr/local/bin/etcdctl {{ etcd_data_dir }}"
shell: "{{ docker_bin_dir }}/docker exec \"$({{ docker_bin_dir }}/docker ps -qf ancestor={{ etcd_image_repo }}:{{ etcd_image_tag }})\" cp /usr/local/bin/etcdctl {{ etcd_data_dir }}"
when: container_manager == "docker"
- name: Copy etcdctl script to host
shell: "crictl exec \"$(crictl ps -q --image {{ etcd_image_repo }}:{{ etcd_image_tag }})\" cp /usr/local/bin/etcdctl {{ etcd_data_dir }}"
shell: "{{ bin_dir }}/crictl exec \"$({{ bin_dir }}/crictl ps -q --image {{ etcd_image_repo }}:{{ etcd_image_tag }})\" cp /usr/local/bin/etcdctl {{ etcd_data_dir }}"
when: container_manager in ['crio', 'containerd']
- name: Copy etcdctl to {{ bin_dir }}