Fix: Remove payload env variables from Dockerfile and deploy.yml to resolve build failure
Some checks failed
Build & Deploy / 🔍 Prepare (push) Successful in 7s
Build & Deploy / 🏗️ Build (push) Failing after 9m32s
Build & Deploy / 🚀 Deploy (push) Has been skipped
Build & Deploy / 🩺 Smoke Test (push) Has been skipped
Build & Deploy / 🔔 Notify (push) Successful in 1s

This commit is contained in:
2026-05-05 16:06:54 +02:00
parent 222140aa44
commit a02a419879
2 changed files with 6 additions and 19 deletions

View File

@@ -13,8 +13,7 @@ ARG S3_SECRET_KEY
ARG S3_BUCKET
ARG S3_REGION
ARG S3_PREFIX
ARG DATABASE_URI
ARG PAYLOAD_SECRET
ARG BUILD_ID
# Environment variables for Next.js build
@@ -27,8 +26,7 @@ ENV S3_SECRET_KEY=$S3_SECRET_KEY
ENV S3_BUCKET=$S3_BUCKET
ENV S3_REGION=$S3_REGION
ENV S3_PREFIX=$S3_PREFIX
ENV DATABASE_URI=$DATABASE_URI
ENV PAYLOAD_SECRET=$PAYLOAD_SECRET
ENV SKIP_RUNTIME_ENV_VALIDATION=true
ENV NEXT_BUILD_WORKERS=1
ENV NEXT_DISABLE_SOURCEMAPS=true
@@ -81,8 +79,7 @@ COPY --from=builder --chown=1001:65533 /app/apps/web/public ./public
COPY --from=builder --chown=1001:65533 /app/apps/web/.next/standalone ./
COPY --from=builder --chown=1001:65533 /app/apps/web/.next/static ./apps/web/.next/static
# Explicitly copy Payload dynamically generated importMap.js excluded by Standalone tracing
COPY --from=builder --chown=1001:65533 /app/apps/web/app/(payload)/admin/importMap.js ./apps/web/app/(payload)/admin/importMap.js
# Fix permissions for the non-root user (Standard uid/gid from base image)
USER nextjs