use zj_image instead of image as loopvar
Change-Id: I2b34253e736252994681b7c69eb051c8a0659671
This commit is contained in:
parent
bee0c6ae2f
commit
4feb02f87e
@ -5,12 +5,12 @@
|
||||
- name: Push tag to intermediate registry
|
||||
command: >-
|
||||
skopeo --insecure-policy copy
|
||||
docker://127.0.0.1:{{ socat_port }}/{{ image.repository | regex_replace('^docker\.io/(.*)', '\1') }}:{{ zj_image_tag }}
|
||||
docker://{{ intermediate_registry.host | ipwrap }}:{{ intermediate_registry.port }}/{{ image.repository }}:{{ zuul.build }}_{{ zj_image_tag }}
|
||||
docker://127.0.0.1:{{ socat_port }}/{{ zj_image.repository | regex_replace('^docker\.io/(.*)', '\1') }}:{{ zj_image_tag }}
|
||||
docker://{{ intermediate_registry.host | ipwrap }}:{{ intermediate_registry.port }}/{{ zj_image.repository }}:{{ zuul.build }}_{{ zj_image_tag }}
|
||||
retries: 3
|
||||
register: result
|
||||
until: result is success
|
||||
loop: "{{ image.tags | default(['latest']) }}"
|
||||
loop: "{{ zj_image.tags | default(['latest']) }}"
|
||||
loop_control:
|
||||
loop_var: zj_image_tag
|
||||
|
||||
@ -19,12 +19,12 @@
|
||||
data:
|
||||
zuul:
|
||||
artifacts:
|
||||
- name: "{{ image.repository }}:{{ zj_image_tag }}"
|
||||
url: "docker://{{ intermediate_registry.host | ipwrap }}:{{ intermediate_registry.port }}/{{ image.repository }}:{{ zuul.build }}_{{ zj_image_tag }}"
|
||||
- name: "{{ zj_image.repository }}:{{ zj_image_tag }}"
|
||||
url: "docker://{{ intermediate_registry.host | ipwrap }}:{{ intermediate_registry.port }}/{{ zj_image.repository }}:{{ zuul.build }}_{{ zj_image_tag }}"
|
||||
metadata:
|
||||
type: container_image
|
||||
repository: "{{ image.repository }}"
|
||||
repository: "{{ zj_image.repository }}"
|
||||
tag: "{{ zj_image_tag }}"
|
||||
loop: "{{ image.tags | default(['latest']) }}"
|
||||
loop: "{{ zj_image.tags | default(['latest']) }}"
|
||||
loop_control:
|
||||
loop_var: zj_image_tag
|
||||
|
@ -80,7 +80,7 @@
|
||||
include_tasks: push-image.yaml
|
||||
loop: "{{ docker_images }}"
|
||||
loop_control:
|
||||
loop_var: image
|
||||
loop_var: zj_image
|
||||
always:
|
||||
- name: Remove docker user config
|
||||
command: "shred ~/.docker/config.json"
|
||||
|
Loading…
Reference in New Issue
Block a user