# Build-only: compiles web, server, and shared TypeScript bundles FROM node:22-alpine AS builder WORKDIR /app COPY package.json package-lock.json ./ RUN npm ci COPY . . RUN npm run build # Final image exposes the compiled output only FROM node:22-alpine WORKDIR /app COPY --from=builder /app/web/dist ./web/dist COPY --from=builder /app/server/dist ./server/dist COPY --from=builder /app/shared/dist ./shared/dist COPY --from=builder /app/package.json ./ # The server entrypoint EXPOSE 3000 CMD ["node", "server/dist/index.js"]