Files
parcer/server/Dockerfile

25 lines
597 B
Docker
Raw Normal View History

2024-11-01 16:28:05 +05:30
# Use Node.js with Ubuntu instead of Alpine for better Playwright support
FROM mcr.microsoft.com/playwright:v1.40.0-jammy
2024-11-01 16:04:22 +05:30
2024-11-01 16:28:05 +05:30
# Set working directory
2024-11-01 16:04:22 +05:30
WORKDIR /app
2024-11-01 16:28:05 +05:30
# Install node dependencies
2024-11-01 16:04:22 +05:30
COPY package*.json ./
COPY maxun-core ./maxun-core
COPY src ./src
COPY server ./server
COPY tsconfig.json ./
COPY server/tsconfig.json ./server/
# Install dependencies
RUN npm install
2024-11-01 16:28:05 +05:30
# Install Playwright browsers and dependencies
RUN npx playwright install --with-deps chromium firefox webkit
2024-11-01 16:04:22 +05:30
# Expose the backend port
EXPOSE 8080
# Start the backend using the server script
CMD ["npm", "run", "server"]