hirann commited on
Commit
9bc697b
·
verified ·
1 Parent(s): 8505f8d

Upload Dockerfile with huggingface_hub

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -12
Dockerfile CHANGED
@@ -4,18 +4,9 @@ FROM unsloth/unsloth:latest
4
  USER root
5
  WORKDIR /app
6
 
7
- # Install server-specific dependencies on top of the Unsloth environment
8
- # We use the /opt/venv which is the standard location in Unsloth images
9
- RUN /opt/venv/bin/pip install --no-cache-dir \
10
- fastapi \
11
- uvicorn[standard] \
12
- gradio \
13
- openenv-core \
14
- networkx \
15
- matplotlib \
16
- plotly \
17
- pyyaml \
18
- rich
19
 
20
  # Copy the project files
21
  COPY . .
@@ -29,5 +20,8 @@ ENV UNSLOTH_USE_VLLM=0
29
  # Expose the default Gradio/FastAPI port
30
  EXPOSE 7860
31
 
 
 
 
32
  # Start the FastAPI server (which mounts the Gradio demo at /demo)
33
  CMD ["/opt/venv/bin/python", "-m", "uvicorn", "server.main:app", "--host", "0.0.0.0", "--port", "7860"]
 
4
  USER root
5
  WORKDIR /app
6
 
7
+ # Install dependencies using the requirements.txt file
8
+ COPY requirements.txt .
9
+ RUN /opt/venv/bin/pip install --no-cache-dir -r requirements.txt
 
 
 
 
 
 
 
 
 
10
 
11
  # Copy the project files
12
  COPY . .
 
20
  # Expose the default Gradio/FastAPI port
21
  EXPOSE 7860
22
 
23
+ # Ensure we override the base image's entrypoint (which starts supervisord)
24
+ ENTRYPOINT []
25
+
26
  # Start the FastAPI server (which mounts the Gradio demo at /demo)
27
  CMD ["/opt/venv/bin/python", "-m", "uvicorn", "server.main:app", "--host", "0.0.0.0", "--port", "7860"]