# Use an official Node.js runtime as base image | |
FROM node:18 | |
# Set working directory | |
WORKDIR /app | |
# Install Node.js dependencies | |
RUN npm install express axios cheerio cors string-similarity | |
# Set Puppeteer to use Playwright's Chromium | |
ENV PUPPETEER_EXECUTABLE_PATH=/usr/bin/chromium | |
# Copy project files | |
COPY . . | |
# Expose API port | |
EXPOSE 7860 | |
# Run the application | |
CMD ["node", "server.js"] |