Files
venture_studio-site/Dockerfile
2026-09-28 12:29:52 +05:30

33 lines
518 B
Docker

# 1. Build Stage
FROM node:22-alpine AS build
WORKDIR /app
# Copy dependency files
COPY package*.json ./
# Install dependencies
RUN npm ci
# Copy source code
COPY . .
# Build with node-server preset (not cloudflare-module)
RUN NITRO_PRESET=node-server npm run build
# 2. Production Stage
FROM node:22-alpine
WORKDIR /app
# Copy built output from build stage
COPY --from=build /app/.output ./.output
EXPOSE 3000
ENV NODE_ENV=production
ENV PORT=3000
ENV HOST=0.0.0.0
CMD ["node", ".output/server/index.mjs"]