Files
coffee/Dockerfile
Julien Calixte 31b6334bd7 Switch Nginx to port 3000 for Coolify
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-28 23:07:13 +01:00

28 lines
488 B
Docker

# Build stage
FROM node:22-alpine AS builder
RUN corepack enable && corepack prepare pnpm@10 --activate
WORKDIR /app
COPY package.json pnpm-lock.yaml ./
RUN pnpm install --frozen-lockfile
COPY . .
# Pass your deployed URL as a build arg
ARG VITE_APP_URL
ENV VITE_APP_URL=$VITE_APP_URL
RUN pnpm build
# Serve stage
FROM nginx:alpine
COPY --from=builder /app/dist /usr/share/nginx/html
COPY nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE 3000
CMD ["nginx", "-g", "daemon off;"]