tejashsr commited on
Commit
fb84c7a
·
verified ·
1 Parent(s): db807c9

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +3 -8
Dockerfile CHANGED
@@ -9,16 +9,11 @@ RUN apt-get update && apt-get install -y build-essential && rm -rf /var/lib/apt/
9
  COPY requirements.txt .
10
  RUN pip install --no-cache-dir -r requirements.txt
11
 
12
- # Download Spacy model during build (CRITICAL FOR SPEED)
13
  RUN python -m spacy download en_core_web_sm
14
 
15
- # Copy App Code
16
  COPY . .
17
 
18
- # Create cache directory with permissions
19
- RUN mkdir -p /app/cache && chmod 777 /app/cache
20
- ENV TRANSFORMERS_CACHE=/app/cache
21
- ENV SENTENCE_TRANSFORMERS_HOME=/app/cache
22
-
23
- # Start Server
24
  CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]
 
9
  COPY requirements.txt .
10
  RUN pip install --no-cache-dir -r requirements.txt
11
 
12
+ # Download Spacy model during build to save time
13
  RUN python -m spacy download en_core_web_sm
14
 
15
+ # Copy your code
16
  COPY . .
17
 
18
+ # Hugging Face uses port 7860 by default
 
 
 
 
 
19
  CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]