Manveer04 commited on
Commit
2f71fad
·
verified ·
1 Parent(s): 1ba6a02

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +5 -27
Dockerfile CHANGED
@@ -1,29 +1,7 @@
1
- FROM python:3.11-slim
2
-
3
- ENV PIP_DISABLE_PIP_VERSION_CHECK=1 \
4
- PYTHONDONTWRITEBYTECODE=1 \
5
- PYTHONUNBUFFERED=1 \
6
- PLAYWRIGHT_BROWSERS_PATH=0
7
-
8
- RUN apt-get update && apt-get install -y --no-install-recommends \
9
- ca-certificates curl \
10
- fonts-unifont fonts-dejavu-core fonts-noto-core \
11
- libnss3 libxss1 libatk-bridge2.0-0 libxkbcommon0 libxcomposite1 \
12
- libxdamage1 libxfixes3 libgtk-3-0 libdrm2 libgbm1 libasound2 \
13
- libpangocairo-1.0-0 libpango-1.0-0 libcairo2 libatspi2.0-0 \
14
- libxrandr2 libxcursor1 libxi6 libxtst6 libxinerama1 libxcb1 \
15
- && rm -rf /var/lib/apt/lists/*
16
-
17
- # ⬇️ add httpx here
18
- RUN pip install --no-cache-dir \
19
- fastapi==0.115.4 uvicorn[standard]==0.30.6 playwright==1.48.0 httpx==0.27.2
20
-
21
- RUN python -m playwright install chromium
22
-
23
  WORKDIR /app
24
- COPY app.py /app/app.py
25
-
26
- ENV PORT=7860
27
  EXPOSE 7860
28
-
29
- CMD ["sh","-c","uvicorn app:app --host 0.0.0.0 --port ${PORT:-7860}"]
 
1
+ FROM node:20-alpine
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
2
  WORKDIR /app
3
+ COPY package.json ./
4
+ RUN npm ci --only=production || npm i --omit=dev
5
+ COPY server.js ./
6
  EXPOSE 7860
7
+ CMD ["node", "server.js"]