# Use a lightweight Node.js image
FROM node:20-alpine
# Set working directory
WORKDIR /app
# Copy package files
COPY package*.json ./
# Install dependencies
RUN npm ci
# Copy source code
COPY . .
# Build the application
RUN npm run build
# Expose the port
EXPOSE 3000
# Start the SSE server
CMD ["node", "build/sse.js"]