From ae1f0cc354dc08b0848b951c8cdfe44b36060d35 Mon Sep 17 00:00:00 2001 From: RodolfoFigueroa <4rodolfofigueroa2@gmail.com> Date: Fri, 1 May 2026 11:04:58 -0600 Subject: [PATCH 1/8] Remove platforms incompatible with node image --- .github/workflows/release.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 5a54ff0..1a1e136 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -112,7 +112,7 @@ jobs: ghcr.io/${{ env.REPO_LC }}:${{ github.ref_name }} cache-from: type=gha cache-to: type=gha,mode=max - platforms: linux/amd64,linux/386,linux/arm64,linux/arm/v7 + platforms: linux/amd64,linux/arm64,linux/arm/v7 build-args: | TARGETARCH @@ -155,6 +155,6 @@ jobs: tags: ghcr.io/${{ env.REPO_LC }}:dev cache-from: type=gha cache-to: type=gha,mode=max - platforms: linux/amd64,linux/386,linux/arm64,linux/arm/v7 + platforms: linux/amd64,linux/arm64,linux/arm/v7 build-args: | TARGETARCH From 033069459e8ec4436fef653f294f72aa61e05da6 Mon Sep 17 00:00:00 2001 From: RodolfoFigueroa <4rodolfofigueroa2@gmail.com> Date: Fri, 1 May 2026 11:10:20 -0600 Subject: [PATCH 2/8] Replace lowercase script with official action --- .github/workflows/release.yml | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 1a1e136..4829382 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -93,10 +93,11 @@ jobs: username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} - - name: Convert repository name to lowercase - run: | - REPO_LC=$(echo "${{ github.repository }}" | tr '[:upper:]' '[:lower:]') - echo "REPO_LC=$REPO_LC" >> $GITHUB_ENV + - name: Extract metadata (tags, labels) for Docker + id: meta + uses: docker/metadata-action@v5 + with: + images: ghcr.io/${{ github.repository }} - name: Set up Docker Buildx uses: docker/setup-buildx-action@v2 @@ -141,8 +142,11 @@ jobs: username: ${{ github.actor }} password: ${{ secrets.GITHUB_TOKEN }} - - name: Convert repository name to lowercase - run: echo "REPO_LC=$(echo '${{ github.repository }}' | tr '[:upper:]' '[:lower:]')" >> $GITHUB_ENV + - name: Extract metadata (tags, labels) for Docker + id: meta + uses: docker/metadata-action@v5 + with: + images: ghcr.io/${{ github.repository }} - name: Set up Docker Buildx uses: docker/setup-buildx-action@v2 From e73c33a791301ca659376e682b9244b1ef3f4669 Mon Sep 17 00:00:00 2001 From: RodolfoFigueroa <4rodolfofigueroa2@gmail.com> Date: Fri, 1 May 2026 11:10:26 -0600 Subject: [PATCH 3/8] Bump some action versions --- .github/workflows/release.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 4829382..c47adfd 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -87,7 +87,7 @@ jobs: fetch-depth: 0 - name: Login to ghcr.io - uses: docker/login-action@v2 + uses: docker/login-action@v3 with: registry: ghcr.io username: ${{ github.actor }} @@ -100,11 +100,11 @@ jobs: images: ghcr.io/${{ github.repository }} - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v2 + uses: docker/setup-buildx-action@v3 - name: Build and push id: build-and-push - uses: docker/build-push-action@v5 + uses: docker/build-push-action@v6 with: context: . push: true @@ -136,7 +136,7 @@ jobs: fetch-depth: 0 - name: Login to ghcr.io - uses: docker/login-action@v2 + uses: docker/login-action@v3 with: registry: ghcr.io username: ${{ github.actor }} @@ -149,10 +149,10 @@ jobs: images: ghcr.io/${{ github.repository }} - name: Set up Docker Buildx - uses: docker/setup-buildx-action@v2 + uses: docker/setup-buildx-action@v3 - name: Build and push dev image - uses: docker/build-push-action@v5 + uses: docker/build-push-action@v6 with: context: . push: true From 72fc2af02e4568fc4f024a7f08006e1cce6da9e7 Mon Sep 17 00:00:00 2001 From: RodolfoFigueroa <4rodolfofigueroa2@gmail.com> Date: Fri, 1 May 2026 11:14:35 -0600 Subject: [PATCH 4/8] Add action manual trigger for testing --- .github/workflows/release.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c47adfd..9e64566 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -7,6 +7,7 @@ on: - dev pull_request: branches: ['*'] + workflow_dispatch: name: Latest Release From f5eb4ab9017b9c0bba7c48d7f56392a5e2812b19 Mon Sep 17 00:00:00 2001 From: RodolfoFigueroa <4rodolfofigueroa2@gmail.com> Date: Fri, 1 May 2026 11:19:22 -0600 Subject: [PATCH 5/8] Pass missing metadata to builder --- .github/workflows/release.yml | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 9e64566..13d14ed 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -99,6 +99,9 @@ jobs: uses: docker/metadata-action@v5 with: images: ghcr.io/${{ github.repository }} + tags: | + type=ref,event=tag + type=raw,value=latest - name: Set up Docker Buildx uses: docker/setup-buildx-action@v3 @@ -109,9 +112,8 @@ jobs: with: context: . push: true - tags: | - ghcr.io/${{ env.REPO_LC }}:latest - ghcr.io/${{ env.REPO_LC }}:${{ github.ref_name }} + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} cache-from: type=gha cache-to: type=gha,mode=max platforms: linux/amd64,linux/arm64,linux/arm/v7 @@ -148,6 +150,8 @@ jobs: uses: docker/metadata-action@v5 with: images: ghcr.io/${{ github.repository }} + tags: | + type=raw,value=dev - name: Set up Docker Buildx uses: docker/setup-buildx-action@v3 @@ -157,7 +161,8 @@ jobs: with: context: . push: true - tags: ghcr.io/${{ env.REPO_LC }}:dev + tags: ${{ steps.meta.outputs.tags }} + labels: ${{ steps.meta.outputs.labels }} cache-from: type=gha cache-to: type=gha,mode=max platforms: linux/amd64,linux/arm64,linux/arm/v7 From c1e7a2c2e368d48219c70d54650b803659aa99de Mon Sep 17 00:00:00 2001 From: RodolfoFigueroa <4rodolfofigueroa2@gmail.com> Date: Fri, 1 May 2026 11:23:56 -0600 Subject: [PATCH 6/8] Add dummy `dist` directory to silence go:embed --- .github/workflows/release.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 13d14ed..14d398d 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -24,6 +24,11 @@ jobs: - uses: actions/setup-go@v4 with: go-version: '1.24' + + # Create a dummy directory to appease the go:embed typechecker + - name: Create dummy dist directory + run: mkdir -p src/web/dist && touch src/web/dist/.keep + - name: golangci-lint uses: golangci/golangci-lint-action@v8.0.0 with: From 5a45dcac18aef93615cf6f72745f040fba9528b5 Mon Sep 17 00:00:00 2001 From: RodolfoFigueroa <4rodolfofigueroa2@gmail.com> Date: Fri, 1 May 2026 11:25:50 -0600 Subject: [PATCH 7/8] Forgot go:embed ignored files starting with a dot --- .github/workflows/release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 14d398d..7012817 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -27,7 +27,7 @@ jobs: # Create a dummy directory to appease the go:embed typechecker - name: Create dummy dist directory - run: mkdir -p src/web/dist && touch src/web/dist/.keep + run: mkdir -p src/web/dist && touch src/web/dist/index.html - name: golangci-lint uses: golangci/golangci-lint-action@v8.0.0 From 3a5c4bc6752a5e9686f3d3264b12abea6d4da8d8 Mon Sep 17 00:00:00 2001 From: RodolfoFigueroa <4rodolfofigueroa2@gmail.com> Date: Fri, 1 May 2026 11:31:47 -0600 Subject: [PATCH 8/8] Run build steps in native architecture to avoid QEMU crash --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 2fc7bdb..64f4a52 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,11 +1,11 @@ -FROM node:20-alpine AS ui-builder +FROM --platform=$BUILDPLATFORM node:20-alpine AS ui-builder WORKDIR /app/src/web/frontend COPY src/web/frontend/package*.json ./ RUN npm ci COPY src/web/frontend/ ./ RUN npm run build -FROM golang:1.24-alpine AS builder +FROM --platform=$BUILDPLATFORM golang:1.24-alpine AS builder # Set the working directory WORKDIR /app