FROM node:24-alpine

WORKDIR /app

# Install dependencies first (caching)
COPY package*.json ./
RUN npm install

# Copy source code and frontend
COPY . .

# Build typescript
RUN npm run build

EXPOSE 3000

CMD ["npm", "start"]
