Skip to content

v0.16.2

v0.16.2 #90

name: ICR | build and push
on:
workflow_dispatch:
inputs:
tag:
description: 'Tag for images'
required: true
release:
types: [published]
permissions:
contents: read
jobs:
icr_build_and_push:
runs-on: ubuntu-latest
strategy:
matrix:
include:
- imagename: qiskit-serverless/ray-node
dockerfile: Dockerfile-ray-node
platforms: linux/amd64,linux/arm64
- imagename: qiskit-serverless/gateway
dockerfile: ./gateway/Dockerfile
platforms: linux/amd64,linux/arm64
- imagename: qiskit-serverless/proxy
dockerfile: ./proxy/Dockerfile
platforms: linux/amd64,linux/arm64
steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 #4.1.7
- name: Login to IBM Container Registry
uses: docker/login-action@9780b0c442fbb1117ed29e0efdff1e18412f7567 #3.3.0
with:
registry: icr.io
username: iamapikey
password: ${{ secrets.IBMCLOUD_API_KEY }}
- name: Set up QEMU
uses: docker/setup-qemu-action@49b3bc8e6bdd4a60e6116a5414239cba5943d3cf #3.2.0
with:
platforms: 'arm64,amd64'
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@988b5a0280414f521da01fcc63a27aeeb4b104db #3.6.1
- name: Build and push on dispatch
if : github.event_name == 'workflow_dispatch'
uses: ./.github/actions/icr-build-and-push-images
with:
tag: ${{ github.event.inputs.tag }}
name: ${{ matrix.imagename }}
dockerfile: ${{ matrix.dockerfile }}
platforms: ${{ matrix.platforms }}
- name: Set version from tag
if : github.event_name == 'release' && github.event.action == 'published'
id: set-version-from-tag
run: echo "VERSION=${GITHUB_REF_NAME/v}" >> $GITHUB_OUTPUT
- name: Build and push on release
if : github.event_name == 'release' && github.event.action == 'published'
uses: ./.github/actions/icr-build-and-push-images
with:
tag: ${{ steps.set-version-from-tag.outputs.VERSION }}
name: ${{ matrix.imagename }}
dockerfile: ${{ matrix.dockerfile }}
platforms: ${{ matrix.platforms }}