FROM node:20-alpine

WORKDIR /app

# Copy root package files
COPY package.json package-lock.json* ./

# Install production dependencies
RUN npm ci --omit=dev

# Copy server source code
COPY server ./server

# Expose port
EXPOSE 3000

# Start server
CMD ["node", "server/index.js"]
