Backend Dockerfile runs drizzle-kit migrate on start, frontend serves the built Vite app via nginx and proxies /api to the backend container. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TBf3yfnnHzMQ5qhLV2285A
11 lines
214 B
Docker
11 lines
214 B
Docker
FROM node:22-alpine
|
|
WORKDIR /app
|
|
COPY package.json package-lock.json ./
|
|
RUN npm ci
|
|
COPY . .
|
|
RUN npm run build
|
|
|
|
ENV NODE_ENV=production
|
|
EXPOSE 4000
|
|
CMD ["sh", "-c", "npx drizzle-kit migrate && node dist/server.js"]
|