Skip to content

Fix upstream build and push CI job #32

Fix upstream build and push CI job

Fix upstream build and push CI job #32

name: Build and push images
on:
push:
branches:
- main
- release-*
pull_request:
branches:
- main
workflow_dispatch:
jobs:
build_push:
strategy:
fail-fast: false
matrix:
include:
- name: virt-v2v
file: build/virt-v2v/Containerfile-upstream
repo: forklift-virt-v2v
runs-on: ubuntu-latest
env:
REGISTRY: quay.io
# Set tag 'latest' on main branch
REGISTRY_TAG: ${{ (github.head_ref||github.ref_name)=='main' && 'latest' || (github.head_ref||github.ref_name) }}
REGISTRY_ORG: kubev2v
steps:
- name: Checkout forklift
uses: actions/checkout@v4
- name: Login to quay.io with bot account
uses: docker/login-action@v3
with:
registry: quay.io
username: ${{ secrets.QUAY_USERNAME }}
password: ${{ secrets.QUAY_TOKEN }}
- name: Build and push ${{ matrix.name }} image to quay.io
uses: docker/build-push-action@v6
with:
push: true
file: "${{ matrix.file }}"
tags: mnecas0/${{ matrix.repo }}:${{ env.REGISTRY_TAG }}