ramedde commited on
Commit
1d03122
·
verified ·
1 Parent(s): 94214ef

Create dockerfile

Browse files
Files changed (1) hide show
  1. dockerfile +44 -0
dockerfile ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ FROM python:3.13
2
+
3
+ # Install system dependencies
4
+ RUN apt-get update && apt-get install -y \
5
+ git \
6
+ git-lfs \
7
+ ffmpeg \
8
+ libsm6 \
9
+ libxext6 \
10
+ cmake \
11
+ rsync \
12
+ libgl1 \
13
+ && rm -rf /var/lib/apt/lists/* \
14
+ && git lfs install
15
+
16
+ # Create user and working directory
17
+ RUN useradd -m -u 1000 user
18
+ WORKDIR /app
19
+
20
+ # Upgrade pip
21
+ RUN pip install --no-cache-dir pip -U
22
+
23
+ # Copy and install YOUR requirements first (with gradio 5.29.0)
24
+ COPY requirements.txt .
25
+ RUN pip install --no-cache-dir -r requirements.txt
26
+
27
+ # Install HF Space runtime deps
28
+ RUN pip install --no-cache-dir \
29
+ "huggingface-hub>=0.30" \
30
+ "hf-transfer>=0.1.4" \
31
+ "protobuf<4" \
32
+ "click<8.1" \
33
+ uvicorn \
34
+ websockets \
35
+ spaces
36
+
37
+ # Copy app files
38
+ COPY --chown=user . /app
39
+
40
+ USER user
41
+
42
+ EXPOSE 7860
43
+
44
+ CMD ["python", "app.py"]