From 798f435951d382bff51ec794ecd492a38d66f6b8 Mon Sep 17 00:00:00 2001 From: Fabian Schmitt <21021337+fabian-schmitt@users.noreply.github.com> Date: Mon, 14 Sep 2026 15:07:57 +0200 Subject: [PATCH 1/3] feat(ci): add workflow to build and publish container image on GHCR --- .github/workflows/build-capstk-container.yml | 44 ++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 .github/workflows/build-capstk-container.yml diff --git a/.github/workflows/build-capstk-container.yml b/.github/workflows/build-capstk-container.yml new file mode 100644 index 0000000..f50df48 --- /dev/null +++ b/.github/workflows/build-capstk-container.yml @@ -0,0 +1,44 @@ +name: build-CAPSTK-container + +on: + push: + branches: [main] + tags: ["v*"] + +permissions: + contents: read + packages: write + +jobs: + build: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v5 + + - uses: docker/setup-buildx-action@v3 + + - uses: docker/login-action@v3 + with: + registry: ghcr.io + username: ${{ github.actor }} + password: ${{ secrets.GITHUB_TOKEN }} + + - id: meta + uses: docker/metadata-action@v5 + with: + images: ghcr.io/${{ github.repository }} + tags: | + type=ref,event=branch + type=semver,pattern={{version}} + type=sha + + - uses: docker/build-push-action@v6 + with: + context: . + platforms: linux/amd64,linux/arm64 + push: true + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} + cache-from: type=gha + cache-to: type=gha,mode=max + \ No newline at end of file From 39be09f302642f9fd9d40afdfb9f4a7412d7076f Mon Sep 17 00:00:00 2001 From: Fabian Schmitt <21021337+fabian-schmitt@users.noreply.github.com> Date: Mon, 14 Sep 2026 15:38:02 +0200 Subject: [PATCH 2/3] feat(dockerfile): cross-compile builder stage --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 5f13ee5..c90623c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,5 +1,5 @@ # Build the manager binary -FROM golang:1.26 AS builder +FROM --platform=$BUILDPLATFORM golang:1.26 AS builder ARG TARGETOS ARG TARGETARCH From 7857d1a07ab9b3d1fc6b559067a6fb302e64005a Mon Sep 17 00:00:00 2001 From: Jan Larwig Date: Tue, 15 Sep 2026 09:57:34 +0200 Subject: [PATCH 3/3] ci: fix pipeline name Signed-off-by: Jan Larwig --- .../{build-capstk-container.yml => build-container-image.yml} | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) rename .github/workflows/{build-capstk-container.yml => build-container-image.yml} (96%) diff --git a/.github/workflows/build-capstk-container.yml b/.github/workflows/build-container-image.yml similarity index 96% rename from .github/workflows/build-capstk-container.yml rename to .github/workflows/build-container-image.yml index f50df48..bf3815d 100644 --- a/.github/workflows/build-capstk-container.yml +++ b/.github/workflows/build-container-image.yml @@ -1,4 +1,4 @@ -name: build-CAPSTK-container +name: Build container image on: push: @@ -41,4 +41,3 @@ jobs: labels: ${{ steps.meta.outputs.labels }} cache-from: type=gha cache-to: type=gha,mode=max - \ No newline at end of file