zuul-jobs/roles/push-to-intermediate-registry/tasks/main.yaml
Monty Taylor 10cea0b22d Don't try to push images when the build failed
When an image build fails we're still trying to push the image to
the registry. This isn't going to work, as there is no image to
push since the build failed.

Add a check for the job being in a success state for if we're
pushing images. This way we can properly report FAILURE instead of
POST_FAILURE.

Change-Id: Idba5c8997111c6e84b44bc970394b58387519666
2019-07-28 14:07:47 -04:00

6 lines
153 B
YAML

- name: Push images to intermediate registry
when:
- docker_images is defined
- zuul_success | default(true) | bool
include_tasks: push.yaml