test / Dockerfile
lljz66's picture
Update Dockerfile
7da6aba verified
raw
history blame contribute delete
774 Bytes
FROM node:20-slim
RUN apt-get update && apt-get install -y \
wget gnupg ca-certificates fonts-liberation \
libasound2 libatk-bridge2.0-0 libatk1.0-0 libcups2 \
libdbus-1-3 libdrm2 libgbm1 libgtk-3-0 libnspr4 libnss3 \
libx11-xcb1 libxcomposite1 libxdamage1 libxfixes3 \
libxkbcommon0 libxrandr2 xdg-utils \
--no-install-recommends && rm -rf /var/lib/apt/lists/*
WORKDIR /app
COPY package*.json ./
RUN npm install --production
RUN npx playwright install chromium
RUN npx playwright install-deps
COPY . .
# ✅ إنشاء كل المجلدات المطلوبة مع صلاحيات الكتابة
RUN mkdir -p /app/data /app/bl-tmp /app/public
RUN chmod -R 777 /app/bl-tmp /app/data /app/public
ENV PORT=7860
EXPOSE 7860
CMD ["node", "server.js"]