Add unpack script to bundle and turn up verbosity on oc mirror during… #11
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: 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 }}" |