diff --git a/ansible/roles/metacluster/tasks/components.yml b/ansible/roles/metacluster/tasks/components.yml index fcbb0e9..4372f76 100644 --- a/ansible/roles/metacluster/tasks/components.yml +++ b/ansible/roles/metacluster/tasks/components.yml @@ -23,13 +23,16 @@ - name: Parse helm charts for container images ansible.builtin.shell: - cmd: helm template . | yq --no-doc eval '.. | .image? | select(.)' - | sort -u + cmd: helm template . | yq --no-doc eval '.. | .image? | select(.)' - | sort -u | awk '!/ /' chdir: /opt/metacluster/helm-charts/{{ item.key }} register: containerimages loop: "{{ lookup('ansible.builtin.dict', components) }}" loop_control: label: "{{ item.key }}" +- ansible.builtin.debug: + var: containerimages + - name: Pull and store containerimages ansible.builtin.command: cmd: skopeo copy docker://{{ item }} docker-archive:./{{ ( item | regex_findall('[^/:]+'))[-2] }}.tar:{{ item }}