Spaces:
Sleeping

MUHAMMED THABSHEER P commited on
Commit
4c0cabf
·
1 Parent(s): 8c2a169

Github Folder added

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -3
Dockerfile CHANGED
@@ -1,5 +1,9 @@
1
  FROM python:3.11-slim
2
 
 
 
 
 
3
  WORKDIR /app
4
 
5
  # Install system dependencies
@@ -15,9 +19,8 @@ RUN pip install --no-cache-dir -r requirements.txt
15
  # Copy the rest of the application code
16
  COPY . .
17
 
18
- # Standard port for Northflank / Cloud services
19
- ENV PORT=8080
20
- EXPOSE 8080
21
 
22
  # Run the application
23
  CMD ["sh", "-c", "uvicorn app.main:app --host 0.0.0.0 --port ${PORT}"]
 
1
  FROM python:3.11-slim
2
 
3
+ # Set environment variables for Hugging Face
4
+ ENV PYTHONUNBUFFERED=1
5
+ ENV PORT=7860
6
+
7
  WORKDIR /app
8
 
9
  # Install system dependencies
 
19
  # Copy the rest of the application code
20
  COPY . .
21
 
22
+ # Hugging Face expects the app to run on port 7860
23
+ EXPOSE 7860
 
24
 
25
  # Run the application
26
  CMD ["sh", "-c", "uvicorn app.main:app --host 0.0.0.0 --port ${PORT}"]