Browse Source

fix(docker): pin frontend stage to BUILDPLATFORM and drop removed buildx input

node:22-alpine has no manifest for linux/arm/v6, breaking multi-arch
builds. Frontend output is static JS/CSS that doesn't need to be
built per target arch — pin the stage to $BUILDPLATFORM so Vite
always runs on the host. Also drop `install: true` from
setup-buildx-action@v4 (input was removed).
MHSanaei 12 giờ trước cách đây
mục cha
commit
94a7dbfe3c
2 tập tin đã thay đổi với 1 bổ sung3 xóa
  1. 0 2
      .github/workflows/docker.yml
  2. 1 1
      Dockerfile

+ 0 - 2
.github/workflows/docker.yml

@@ -36,8 +36,6 @@ jobs:
 
       - name: Set up Docker Buildx
         uses: docker/setup-buildx-action@v4
-        with:
-          install: true
 
       - name: Login to Docker Hub
         uses: docker/login-action@v4

+ 1 - 1
Dockerfile

@@ -1,7 +1,7 @@
 # ========================================================
 # Stage: Frontend (Vite)
 # ========================================================
-FROM node:22-alpine AS frontend
+FROM --platform=$BUILDPLATFORM node:22-alpine AS frontend
 WORKDIR /src/frontend
 COPY frontend/package.json frontend/package-lock.json ./
 RUN npm ci