pycui commited on
Commit
f1f61a4
1 Parent(s): 625a331

Fix write permission and library access

Browse files
Dockerfile CHANGED
@@ -10,14 +10,19 @@ WORKDIR /realtime_ai_character
10
  COPY requirements.txt /realtime_ai_character
11
  RUN pip install --no-cache-dir --upgrade -r /realtime_ai_character/requirements.txt
12
 
 
 
 
 
 
13
  # Copy the project files
14
- COPY --chown=user ./ /realtime_ai_character
15
 
16
  # Expose 7860. port from the docker image.
17
  EXPOSE 7860
18
 
19
  # Make the entrypoint script executable
20
- RUN chmod +x /realtime_ai_character/entrypoint.sh
21
 
22
  # Run the application
23
- CMD ["/bin/sh", "/realtime_ai_character/entrypoint.sh"]
 
10
  COPY requirements.txt /realtime_ai_character
11
  RUN pip install --no-cache-dir --upgrade -r /realtime_ai_character/requirements.txt
12
 
13
+ ENV HOME=/home/user \
14
+ PATH=/home/user/.local/bin:$PATH
15
+
16
+ WORKDIR $HOME/app
17
+
18
  # Copy the project files
19
+ COPY --chown=user ./ $HOME/app
20
 
21
  # Expose 7860. port from the docker image.
22
  EXPOSE 7860
23
 
24
  # Make the entrypoint script executable
25
+ RUN chmod +x $HOME/app/entrypoint.sh
26
 
27
  # Run the application
28
+ CMD ["/bin/sh", "/home/user/app/entrypoint.sh"]
realtime_ai_character/database/chroma.py CHANGED
@@ -17,6 +17,6 @@ def get_chroma():
17
  chroma = Chroma(
18
  collection_name='llm',
19
  embedding_function=embedding,
20
- persist_directory='/realtime_ai_character/chroma.db'
21
  )
22
  return chroma
 
17
  chroma = Chroma(
18
  collection_name='llm',
19
  embedding_function=embedding,
20
+ persist_directory='/home/user/app/chroma.db'
21
  )
22
  return chroma