mirror of
https://github.com/kubernetes-sigs/kubespray.git
synced 2026-02-28 09:39:12 +03:00
Decrease docker dependency (#7172)
This commit is contained in:
@@ -22,6 +22,12 @@
|
||||
image_path_cached: "{{ download_cache_dir }}/images/{{ image_filename }}"
|
||||
image_path_final: "{{ local_release_dir }}/images/{{ image_filename }}"
|
||||
|
||||
- name: Set image save/load command for docker
|
||||
set_fact:
|
||||
image_save_command: "{{ docker_bin_dir }}/docker save {{ image_reponame }} | gzip -{{ download_compress }} > {{ image_path_final }}"
|
||||
image_load_command: "{{ docker_bin_dir }}/docker load < {{ image_path_final }}"
|
||||
when: container_manager == 'docker'
|
||||
|
||||
- name: Set image save/load command for containerd
|
||||
set_fact:
|
||||
image_save_command: "{{ containerd_bin_dir }}/ctr -n k8s.io image export {{ image_path_final }} {{ image_reponame }}"
|
||||
@@ -34,6 +40,11 @@
|
||||
image_load_command: "skopeo copy docker-archive:{{ image_path_final }} containers-storage:{{ image_reponame }}"
|
||||
when: container_manager == 'crio'
|
||||
|
||||
- name: Set image save/load command for docker on localhost
|
||||
set_fact:
|
||||
image_save_command_on_localhost: "{{ docker_bin_dir }}/docker save {{ image_reponame }} | gzip -{{ download_compress }} > {{ image_path_cached }}"
|
||||
when: container_manager_on_localhost == 'docker'
|
||||
|
||||
- name: Set image save/load command for containerd on localhost
|
||||
set_fact:
|
||||
image_save_command_on_localhost: "{{ containerd_bin_dir }}/ctr -n k8s.io image export {{ image_path_cached }} {{ image_reponame }}"
|
||||
|
||||
Reference in New Issue
Block a user