mike23415 commited on
Commit
bfd5ff2
·
verified ·
1 Parent(s): 7507a36

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -2
Dockerfile CHANGED
@@ -2,8 +2,12 @@ FROM python:3.9
2
 
3
  WORKDIR /app
4
 
5
- COPY requirements.txt .
6
- RUN pip install -r requirements.txt
 
 
 
 
7
 
8
  COPY . .
9
 
 
2
 
3
  WORKDIR /app
4
 
5
+ COPY requirements.txt requirements.txt
6
+ RUN pip install --no-cache-dir -r requirements.txt
7
+
8
+ # Download model explicitly to avoid missing files
9
+ RUN mkdir -p /app/cache && \
10
+ HF_HOME=/app/cache python -c "from transformers import AutoModelForSeq2SeqLM; AutoModelForSeq2SeqLM.from_pretrained('t5-base')"
11
 
12
  COPY . .
13