Skip to content

Add unpack script to bundle and turn up verbosity on oc mirror during… #11

Add unpack script to bundle and turn up verbosity on oc mirror during…

Add unpack script to bundle and turn up verbosity on oc mirror during… #11

name: Build and push container image
on:
push:
branches:
- main
jobs:
build:
name: Build container image
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
steps:
- name: Clone the repository
uses: actions/checkout@v4
- name: Use Buildah to create container image
id: build-image
uses: redhat-actions/buildah-build@v2
with:
image: ocp4-disconnected
tags: latest ${{ github.sha }}
containerfiles: |
./Containerfile
- name: Push container image to registry
id: push-to-ghcr
uses: redhat-actions/push-to-registry@v2
with:
image: ${{ steps.build-image.outputs.image }}
tags: ${{ steps.build-image.outputs.tags }}
registry: ghcr.io/${{ github.repository_owner }}
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Output image URL
run: echo "Image pushed to ${{ steps.push-to-ghcr.outputs.registry-paths }}"