-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
27 lines (19 loc) · 707 Bytes
/
Dockerfile
File metadata and controls
27 lines (19 loc) · 707 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
FROM python:3.13-slim
RUN apt-get update && apt-get install -y --no-install-recommends \
ffmpeg xvfb libnss3 libatk1.0-0 libatk-bridge2.0-0 libcups2 \
libasound2 libxkbcommon0 libgbm1 curl ca-certificates \
&& rm -rf /var/lib/apt/lists/*
# Install runtime deps
RUN pip install --no-cache-dir fastapi uvicorn[standard] typer[all] pydantic rich playwright
# Install Chromium
RUN python -m playwright install --with-deps chromium
WORKDIR /app
COPY app /app/app
ENV PYTHONUNBUFFERED=1 \
SESSIONS_DIR=/sessions \
DISPLAY=:99 \
HOST_ADDR=0.0.0.0 \
HOST_PORT=8080
VOLUME ["/sessions"]
EXPOSE 8080
CMD ["uvicorn", "app.serve.http_api:app", "--host", "0.0.0.0", "--port", "8080"]