Dyno1307 commited on
Commit
b18f2c3
·
verified ·
1 Parent(s): fe5cb5f

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +7 -2
Dockerfile CHANGED
@@ -4,12 +4,17 @@ FROM python:3.10-slim
4
  # Set the working directory in the container
5
  WORKDIR /code
6
 
7
- # Copy the requirements file into the container at /code
8
  COPY ./requirements.txt /code/requirements.txt
9
 
10
- # Install any needed packages specified in requirements.txt
11
  RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
12
 
 
 
 
 
 
13
  # Copy the rest of the application's code
14
  COPY . /code/
15
 
 
4
  # Set the working directory in the container
5
  WORKDIR /code
6
 
7
+ # Copy the requirements file into the container
8
  COPY ./requirements.txt /code/requirements.txt
9
 
10
+ # Install dependencies
11
  RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
12
 
13
+ # ✅ Set Hugging Face cache directory to avoid permission errors
14
+ ENV HF_HOME=/tmp/huggingface
15
+ ENV TRANSFORMERS_CACHE=/tmp/huggingface
16
+ RUN mkdir -p /tmp/huggingface && chmod -R 777 /tmp/huggingface
17
+
18
  # Copy the rest of the application's code
19
  COPY . /code/
20