Skip to content

Build mkosi PodVM binaries #3

Build mkosi PodVM binaries

Build mkosi PodVM binaries #3

name: Build mkosi PodVM binaries
on:
workflow_dispatch:
inputs:
binaries-image:
description: "Prebuild fedora binaries image, as produced by this workflow under ghcr.io/confidential-containers/cloud-api-adaptor/podvm/binaries-fedora"
required: false
jobs:
build-binaries:
name: Build binaries
if : ${{ github.event.inputs.binaries-image == '' }}
runs-on: self-hosted
permissions:
contents: read
packages: write
steps:
- name: Take a pre-action for self-hosted runner
run: |
if [ -f ${HOME}/script/pre_action.sh ]; then
${HOME}/script/pre_action.sh cc-caa
fi
- name: Checkout
uses: actions/checkout@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
#- name: Log in to GitHub Container Registry
# uses: docker/login-action@v2
# with:
# registry: ghcr.io
# username: ${{ github.actor }}
# password: ${{ secrets.GITHUB_TOKEN }}
#- name: Build builder
# uses: docker/build-push-action@v5
# with:
# tags: ghcr.io/${{ github.repository }}/podvm/builder-fedora:${{ github.sha }}
# file: podvm/Dockerfile.podvm_builder.fedora
# push: false
#- name: Build binaries
# uses: docker/build-push-action@v5
# with:
# tags: ghcr.io/${{ github.repository }}/podvm/binaries-fedora:${{ github.sha }}
# file: podvm/Dockerfile.podvm_binaries.fedora
# push: false
# build-args:
# "BUILDER_IMG=ghcr.io/${{ github.repository }}/podvm/builder-fedora:${{ github.sha }}"
- name: Build builder
run: make fedora-binaries-builder
working-directory: podvm-mkosi
- name: Build binaries
run: make binaries
working-directory: podvm-mkosi
- name: Take a post-action
if: always()
run: |
if [ -f ${HOME}/script/post_action.sh ]; then
${HOME}/script/post_action.sh cc-caa
fi