# Use official Node.js image FROM node:18-alpine # Create app directory WORKDIR /app # Copy package files first (for caching) COPY package*.json ./ # Install dependencies RUN npm ci --only=production # Copy source code COPY . . # HuggingFace expects port 7860 ENV PORT=7860 EXPOSE 7860 # Start the server CMD ["npm", "start"]