From 6a348ca9aa8f3cd65df99c7f11227daec45c45c6 Mon Sep 17 00:00:00 2001 From: Itxaka Date: Fri, 7 Feb 2025 16:14:55 +0100 Subject: [PATCH] :robot: Fix master builds of arm64 artifacts (#3174) * Fix master builds of arm64 artifacts Bump kairos-init to fix the nvidia build On artifact push, use the same as the normal docker build but with push Use the proper Dockerfile Pass the correct build args for the Kubernetes version Use the main dir as context --------- Signed-off-by: Itxaka --- .../workflows/reusable-docker-arm-build.yaml | 17 +++++------------ images/Dockerfile | 2 +- 2 files changed, 6 insertions(+), 13 deletions(-) diff --git a/.github/workflows/reusable-docker-arm-build.yaml b/.github/workflows/reusable-docker-arm-build.yaml index cd4a521b..d1aa0ed7 100644 --- a/.github/workflows/reusable-docker-arm-build.yaml +++ b/.github/workflows/reusable-docker-arm-build.yaml @@ -97,7 +97,7 @@ jobs: - name: Build the docker image uses: docker/build-push-action@v6 with: - context: images/ + context: . file: images/Dockerfile platforms: linux/arm64 load: true @@ -106,10 +106,7 @@ jobs: VARIANT=${{ inputs.variant }} MODEL=${{ inputs.model }} BASE_IMAGE=${{ inputs.base_image }} - SOFTWARE_VERSION: ${{ inputs.k3s_version && 'v' || '' }}${{ inputs.k3s_version }} - SOFTWARE_VERSION_PREFIX=k3s - # renovate: datasource=docker depName=quay.io/kairos/framework versioning=semver - FRAMEWORK_VERSION=v2.15.12 + KUBERNETES_VERSION=${{ inputs.k3s_version && 'v' || '' }}${{ inputs.k3s_version }} - name: Grype table if: ${{ github.event_name == 'push' && (github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags/v')) }} uses: anchore/scan-action@v6.0.0 @@ -142,8 +139,8 @@ jobs: if: ${{ github.event_name == 'push' && (github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags/v')) }} uses: docker/build-push-action@v6 with: - context: images/ - file: images/Dockerfile.kairos-${{ inputs.family }} + context: . + file: images/Dockerfile platforms: linux/arm64 push: "true" tags: ${{ env.IMAGE_REF }} @@ -151,11 +148,7 @@ jobs: VARIANT=${{ inputs.variant }} MODEL=${{ inputs.model }} BASE_IMAGE=${{ inputs.base_image }} - RELEASE=${{ env.RELEASE }} - SOFTWARE_VERSION: ${{ inputs.k3s_version && 'v' || '' }}${{ inputs.k3s_version }} - SOFTWARE_VERSION_PREFIX=k3s - # renovate: datasource=docker depName=quay.io/kairos/framework versioning=semver - FRAMEWORK_VERSION=v2.15.12 + KUBERNETES_VERSION=${{ inputs.k3s_version && 'v' || '' }}${{ inputs.k3s_version }} - name: Sign image if: ${{ github.event_name == 'push' && (github.ref == 'refs/heads/master' || startsWith(github.ref, 'refs/tags/v')) }} env: diff --git a/images/Dockerfile b/images/Dockerfile index 0ad44596..742aa3c0 100644 --- a/images/Dockerfile +++ b/images/Dockerfile @@ -1,6 +1,6 @@ ARG BASE_IMAGE=ubuntu:20.04 -FROM quay.io/kairos/kairos-init:v0.2.0 AS kairos-init +FROM quay.io/kairos/kairos-init:v0.2.3 AS kairos-init FROM ${BASE_IMAGE} AS base ARG VARIANT=core