From 28b2bd0a14786228069d1d89d573ff061c7d2237 Mon Sep 17 00:00:00 2001 From: "anthony.bellino" Date: Wed, 8 Sep 2021 11:40:18 -0700 Subject: [PATCH] (zuul) Fix Deckhand post jobs Change-Id: I63c7814ca7a6f7013c194038d14a4721373e9717 --- tools/gate/playbooks/docker-image-build.yaml | 7 +++++-- tools/gate/playbooks/docker-image-tag.yaml | 4 ++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/tools/gate/playbooks/docker-image-build.yaml b/tools/gate/playbooks/docker-image-build.yaml index 3685c541..3a875353 100644 --- a/tools/gate/playbooks/docker-image-build.yaml +++ b/tools/gate/playbooks/docker-image-build.yaml @@ -28,7 +28,7 @@ msg: "{{ tags | to_json }}" - name: Determine tags - shell: echo '{{ tags | to_json }}' | python {{ zuul.project.src_dir }}/tools/image_tags.py + shell: echo '{{ tags | to_json }}' | python3 {{ zuul.project.src_dir }}/tools/image_tags.py environment: BRANCH: "{{ zuul.branch | default('') }}" CHANGE: "{{ zuul.change | default('') }}" @@ -54,7 +54,7 @@ - pip: name: docker version: 2.7.0 - executable: pip + executable: pip3 become: True - name: Make images @@ -78,6 +78,9 @@ - name: Publish images block: + - pip: + name: requests + executable: pip3 - docker_login: username: "{{ airship_deckhand_quay_creds.username }}" password: "{{ airship_deckhand_quay_creds.password }}" diff --git a/tools/gate/playbooks/docker-image-tag.yaml b/tools/gate/playbooks/docker-image-tag.yaml index 0cb8e289..f0375e1d 100644 --- a/tools/gate/playbooks/docker-image-tag.yaml +++ b/tools/gate/playbooks/docker-image-tag.yaml @@ -16,7 +16,7 @@ - hosts: localhost vars: latest_tag: latest - distro: "{{ distro | default ('') }}" + Distro: "{{ distro | default ('') }}" org: airshipit image: deckhand new_tag: "{{ zuul.newrev | default('') }}" @@ -30,7 +30,7 @@ - block: - name: Get id of the distro specific container image currently tagged as latest uri: - url: "{{ quay_repo_api_url }}/{{ org }}/{{ image }}/tag/?specificTag={{ latest_tag }}-{{ distro }}&limit=1" + url: "{{ quay_repo_api_url }}/{{ org }}/{{ image }}/tag/?specificTag={{ latest_tag }}-{{ Distro }}&limit=1" return_content: yes register: response_1 - name: Debug response