# Use official Node.js image FROM node:20-slim # Install dependencies for Puppeteer RUN apt-get update && \ apt-get install -y wget gnupg ca-certificates ffmpeg && \ rm -rf /var/lib/apt/lists/* # Install puppeteer dependencies RUN apt-get update && apt-get install -y \ gconf-service libasound2 libatk1.0-0 libcups2 libdbus-1-3 \ libgdk-pixbuf2.0-0 libnspr4 libnss3 libx11-xcb1 libxcomposite1 \ libxdamage1 libxrandr2 xdg-utils libgbm1 libgtk-3-0 && \ rm -rf /var/lib/apt/lists/* WORKDIR /app COPY package*.json ./ RUN npm install COPY . . # Expose port EXPOSE 3000 CMD ["node", "index.js"]