fix: ensure public dir exists in build, fix serverExternalPackages for Next.js 14
CI/CD / build-and-push (push) Failing after 3s Details

This commit is contained in:
Cloud User 2026-03-16 10:58:39 +09:00
parent 4465be2032
commit 7ddba78d6a
2 changed files with 4 additions and 1 deletions

View File

@ -3,6 +3,7 @@ WORKDIR /app
COPY package*.json ./ COPY package*.json ./
RUN npm ci RUN npm ci
COPY . . COPY . .
RUN mkdir -p public
RUN npm run build RUN npm run build
FROM node:20-alpine AS runner FROM node:20-alpine AS runner

View File

@ -1,7 +1,9 @@
/** @type {import("next").NextConfig} */ /** @type {import("next").NextConfig} */
const nextConfig = { const nextConfig = {
output: "standalone", output: "standalone",
serverExternalPackages: ["@kubernetes/client-node"], experimental: {
serverComponentsExternalPackages: ["@kubernetes/client-node"],
},
}; };
module.exports = nextConfig; module.exports = nextConfig;