Commit
·
f162ecf
1
Parent(s):
f3bf7b5
Editing hugginface_cache permissions
Browse files- Dockerfile +4 -3
Dockerfile
CHANGED
@@ -12,8 +12,9 @@ RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
|
|
12 |
# Copy the content of the local src directory to the working directory
|
13 |
COPY . .
|
14 |
|
15 |
-
# Create a directory for the
|
16 |
-
RUN mkdir -p /code/
|
17 |
-
|
|
|
18 |
# Set the command to run on container start
|
19 |
CMD ["sh", "-c", "export TRANSFORMERS_CACHE=/code/transformers_cache && gunicorn -b 0.0.0.0:7860 app:app"]
|
|
|
12 |
# Copy the content of the local src directory to the working directory
|
13 |
COPY . .
|
14 |
|
15 |
+
# Create a directory for the Hugging Face cache and ensure correct permissions
|
16 |
+
RUN mkdir -p /code/huggingface_cache
|
17 |
+
RUN chmod -R 777 /code/huggingface_cache
|
18 |
+
ENV HF_HOME=/code/huggingface_cache
|
19 |
# Set the command to run on container start
|
20 |
CMD ["sh", "-c", "export TRANSFORMERS_CACHE=/code/transformers_cache && gunicorn -b 0.0.0.0:7860 app:app"]
|