oci-builds #1459
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: oci-builds | ||
on: | ||
push: | ||
branches: [ main ] | ||
tags: | ||
- '*' | ||
pull_request: | ||
branches: [ main ] | ||
jobs: | ||
build-mapt: | ||
name: build-mapt | ||
runs-on: ubuntu-24.04 | ||
steps: | ||
- name: Prepare runner for build multi arch | ||
shell: bash | ||
run: | | ||
sudo apt-get update && sudo apt-get install -y qemu-user-static | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
<<<<<<< HEAD | ||
- name: Build image for PR | ||
if: ${{ github.event_name == 'pull_request' }} | ||
env: | ||
IMG: ghcr.io/redhat-developer/mapt:pr-${{ github.event.number }} | ||
shell: bash | ||
run: | | ||
make oci-build | ||
make oci-save | ||
echo ${IMG} > mapt-image | ||
- name: Build image for Release | ||
if: ${{ github.event_name == 'push' }} | ||
run: | | ||
make oci-build | ||
make oci-save | ||
======= | ||
- name: Build image for PR | ||
if: github.event_name == 'pull_request' | ||
env: | ||
IMG: ghcr.io/redhat-developer/mapt:pr-${{ github.event.number }} | ||
shell: bash | ||
run: | | ||
make oci-build | ||
make oci-save | ||
echo ${IMG} > mapt-image | ||
- name: Upload mapt artifacts for PR | ||
if: github.event_name == 'pull_request' | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: mapt | ||
path: mapt* | ||
>>>>>>> 26393607 (fix: issues while pushing mapt image for PRs and releases) | ||
- name: Log in quay.io | ||
if: github.event_name == 'push' | ||
uses: redhat-actions/podman-login@v1 | ||
with: | ||
registry: quay.io | ||
username: ${{ secrets.QUAY_IO_USERNAME }} | ||
password: ${{ secrets.QUAY_IO_PASSWORD }} | ||
<<<<<<< HEAD | ||
- name: Upload crc-builder | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: mapt | ||
path: mapt* | ||
======= | ||
- name: Build and Push image for Release | ||
if: github.event_name == 'push' | ||
run: | | ||
make oci-build | ||
make oci-push | ||
>>>>>>> 26393607 (fix: issues while pushing mapt image for PRs and releases) |