AI-RESEARCHER-2024 commited on
Commit
430c866
1 Parent(s): 22ffe9e

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +21 -8
Dockerfile CHANGED
@@ -1,13 +1,26 @@
1
  FROM python:3.10
2
- RUN useradd -m -u 1000 user
3
- USER user
4
- ENV HOME=/home/user \
5
- PATH=/home/user/.local/bin:$PATH
6
- WORKDIR $HOME/app
7
- COPY --chown=user . $HOME/app
8
- COPY ./requirements.txt ~/app/requirements.txt
 
 
 
 
 
9
  RUN pip install -r requirements.txt
 
 
 
 
 
10
  RUN ollama serve &
 
 
11
  RUN ollama pull llama3.2:latest
12
- COPY . .
 
13
  CMD ["chainlit", "run", "app.py", "--port", "7860"]
 
1
  FROM python:3.10
2
+
3
+ # Install necessary packages
4
+ RUN apt-get update && apt-get install -y curl
5
+
6
+ # Set the working directory
7
+ WORKDIR /app
8
+
9
+ # Copy application files and requirements
10
+ COPY . /app
11
+ COPY ./requirements.txt /app/requirements.txt
12
+
13
+ # Install Python dependencies
14
  RUN pip install -r requirements.txt
15
+
16
+ # Install Ollama
17
+ RUN curl -fsSL https://ollama.com/install.sh | sh
18
+
19
+ # Start Ollama server in the background
20
  RUN ollama serve &
21
+
22
+ # Pull the Ollama model
23
  RUN ollama pull llama3.2:latest
24
+
25
+ # Set the command to run the Chainlit application
26
  CMD ["chainlit", "run", "app.py", "--port", "7860"]