Red-tech-hub commited on
Commit
ed6e9f4
1 Parent(s): 95d9de7

[revert] revert chode

Browse files
Files changed (1) hide show
  1. Dockerfile +8 -26
Dockerfile CHANGED
@@ -1,40 +1,22 @@
1
- # Use the official Python image as a parent image
2
  FROM python:3.11
3
 
4
- # Create a new user and switch to it
5
  RUN useradd -m -u 1000 user
6
  USER user
7
 
8
- # Set the working directory inside the container
9
  WORKDIR /code
10
 
11
- # Copy requirements file into the container
12
  COPY ./requirements.txt /code/requirements.txt
13
 
14
- # Update the system packages and install sudo
15
- RUN apt-get update && apt-get install -y sudo
16
-
17
- # Change ownership of the /code directory to the new user
18
- RUN sudo chown -R user:user /code
19
-
20
- # Install Python dependencies using pip
21
  RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
22
 
23
- # Copy the rest of the application code into the container
24
- COPY --chown=user:user . /code
25
-
26
- # Copy specific files with the correct ownership
27
- COPY --chown=user:user ./zephyr-7b-beta.Q4_K_S.gguf /code/zephyr-7b-beta.Q4_K_S.gguf
28
- COPY --chown=user:user ./nomic-embed-text-v1.5.Q4_K_S.gguf /code/nomic-embed-text-v1.5.Q4_K_S.gguf
29
 
30
- # Copy additional directories with the correct ownership
31
- COPY --chown=user:user ./data/ /code/data/
32
- COPY --chown=user:user ./chroma_db /code/chroma_db
33
 
34
- # Copy Python scripts with the correct ownership
35
- COPY --chown=user:user ./titleGenerator.py /code/titleGenerator.py
36
- COPY --chown=user:user ./run.py /code/run.py
37
- COPY --chown=user:user ./server.py /code/server.py
38
 
39
- # Specify the command to run the application
40
- CMD ["uvicorn", "server:app", "--host", "0.0.0.0", "--port", "7860"]
 
 
1
  FROM python:3.11
2
 
 
3
  RUN useradd -m -u 1000 user
4
  USER user
5
 
 
6
  WORKDIR /code
7
 
 
8
  COPY ./requirements.txt /code/requirements.txt
9
 
 
 
 
 
 
 
 
10
  RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
11
 
12
+ COPY ./zephyr-7b-beta.Q4_K_S.gguf /code/zephyr-7b-beta.Q4_K_S.gguf
13
+ COPY ./nomic-embed-text-v1.5.Q4_K_S.gguf /code/nomic-embed-text-v1.5.Q4_K_S.gguf
 
 
 
 
14
 
15
+ COPY ./data/ /code/data/
16
+ COPY ./chroma_db /code/chroma_db
 
17
 
18
+ COPY ./titleGenerator.py /code/titleGenerator.py
19
+ COPY ./run.py /code/run.py
20
+ COPY ./server.py /code/server.py
 
21
 
22
+ CMD ["uvicorn", "server:app", "--host", "0.0.0.0", "--port", "7860"]