acadiaway commited on
Commit
fb458a1
·
1 Parent(s): 6b5f4d7

Update Dockerfile and requirements.txt to resolve torch/vllm dependency conflict

Browse files
Files changed (2) hide show
  1. Dockerfile +14 -9
  2. requirements.txt +1 -2
Dockerfile CHANGED
@@ -1,20 +1,25 @@
1
- FROM python:3.13.5-slim
2
 
3
  WORKDIR /app
4
 
5
  RUN apt-get update && apt-get install -y \
6
  build-essential \
7
- curl \
8
- git \
9
  && rm -rf /var/lib/apt/lists/*
10
 
11
- COPY requirements.txt ./
12
- COPY src/ ./src/
13
 
14
- RUN pip3 install -r requirements.txt
 
15
 
16
- EXPOSE 8501
 
 
 
17
 
18
- HEALTHCHECK CMD curl --fail http://localhost:8501/_stcore/health
 
 
 
19
 
20
- ENTRYPOINT ["streamlit", "run", "src/streamlit_app.py", "--server.port=8501", "--server.address=0.0.0.0"]
 
1
+ FROM python:3.12-slim
2
 
3
  WORKDIR /app
4
 
5
  RUN apt-get update && apt-get install -y \
6
  build-essential \
7
+ libpq-dev \
 
8
  && rm -rf /var/lib/apt/lists/*
9
 
10
+ COPY requirements.txt .
 
11
 
12
+ # Install vLLM with GPU support first (fetches compatible Torch)
13
+ RUN pip install --no-cache-dir vllm==0.10.1 --extra-index-url https://download.pytorch.org/whl/cu128
14
 
15
+ # Install remaining dependencies
16
+ RUN pip install --no-cache-dir -r requirements.txt
17
+
18
+ COPY app.py pipeline.py db_utils.py ./
19
 
20
+ ENV HF_HOME=/cache/huggingface
21
+ ENV PORT=8501
22
+
23
+ EXPOSE 8501
24
 
25
+ CMD ["streamlit", "run", "app.py", "--server.port=8501", "--server.address=0.0.0.0"]
requirements.txt CHANGED
@@ -1,7 +1,6 @@
1
- torch==2.8.0
2
  transformers==4.56.0
3
  accelerate==1.10.1
4
  psycopg2-binary==2.9.10
5
  sqlalchemy==2.0.43
6
  python-dotenv==1.1.1
7
- vllm==0.6.2
 
 
1
  transformers==4.56.0
2
  accelerate==1.10.1
3
  psycopg2-binary==2.9.10
4
  sqlalchemy==2.0.43
5
  python-dotenv==1.1.1
6
+ vllm==0.10.1