Elaineyy commited on
Commit
3e00208
·
verified ·
1 Parent(s): 76db52d

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +4 -10
Dockerfile CHANGED
@@ -7,17 +7,11 @@ WORKDIR /app
7
  # Copy project files
8
  COPY . /app
9
 
10
- # Install FastAPI dependencies
11
- RUN pip install --no-cache-dir fastapi uvicorn
12
-
13
- # Install Ollama
14
- RUN curl -fsSL https://ollama.com/install.sh | sh
15
-
16
- # Start Ollama in the background before pulling the model
17
- RUN ollama serve & sleep 5 && ollama pull deepseek-coder-v2
18
 
19
  # Expose port 7860 for FastAPI
20
  EXPOSE 7860
21
 
22
- # Start Ollama and FastAPI server together
23
- CMD ollama serve & uvicorn server:app --host 0.0.0.0 --port 7860
 
7
  # Copy project files
8
  COPY . /app
9
 
10
+ # Install dependencies
11
+ RUN pip install --no-cache-dir fastapi uvicorn torch torchvision torchaudio transformers sentencepiece accelerate
 
 
 
 
 
 
12
 
13
  # Expose port 7860 for FastAPI
14
  EXPOSE 7860
15
 
16
+ # Start the FastAPI server
17
+ CMD ["uvicorn", "server:app", "--host", "0.0.0.0", "--port", "7860"]