diff options
| author | ertopogo <erwin.t.pombett@gmail.com> | 2026-02-19 11:34:16 +0100 |
|---|---|---|
| committer | ertopogo <erwin.t.pombett@gmail.com> | 2026-02-19 11:34:16 +0100 |
| commit | a21bd6a6710d123ef3bfc3c9aab37fc0c276f9c5 (patch) | |
| tree | e2cc828607ea91e5c90ae0ea98c6b7d11324eaf1 /Dockerfile | |
feat: initial project setup - Next.js 16, Payload CMS v3, palette Mapuche
Next.js 16 App Router + TypeScript + Tailwind CSS v4. Payload CMS v3 with PostgreSQL adapter. Mapuche Corporate palette. Public pages, Docker Compose + Caddy, security middleware.
Co-authored-by: Cursor <cursoragent@cursor.com>
Diffstat (limited to 'Dockerfile')
| -rw-r--r-- | Dockerfile | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..328b403 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,36 @@ +FROM node:20-alpine AS base + +# --- Dependencies --- +FROM base AS deps +RUN apk add --no-cache libc6-compat +WORKDIR /app +COPY package.json package-lock.json ./ +RUN npm ci + +# --- Build --- +FROM base AS builder +WORKDIR /app +COPY --from=deps /app/node_modules ./node_modules +COPY . . +ENV NEXT_TELEMETRY_DISABLED=1 +RUN npm run build + +# --- Production --- +FROM base AS runner +WORKDIR /app +ENV NODE_ENV=production +ENV NEXT_TELEMETRY_DISABLED=1 + +RUN addgroup --system --gid 1001 nodejs +RUN adduser --system --uid 1001 nextjs + +COPY --from=builder /app/public ./public +COPY --from=builder --chown=nextjs:nodejs /app/.next/standalone ./ +COPY --from=builder --chown=nextjs:nodejs /app/.next/static ./.next/static + +USER nextjs +EXPOSE 3000 +ENV PORT=3000 +ENV HOSTNAME="0.0.0.0" + +CMD ["node", "server.js"] |
