Spaces:
Sleeping
Sleeping
Commit
·
eed40e3
1
Parent(s):
a4557f8
Add cache directories with proper permissions for model downloads
Browse files- Dockerfile +6 -0
Dockerfile
CHANGED
|
@@ -5,6 +5,12 @@ WORKDIR /app
|
|
| 5 |
# Install ffmpeg for audio processing
|
| 6 |
RUN apt-get update && apt-get install -y ffmpeg && apt-get clean
|
| 7 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 8 |
# Install dependencies
|
| 9 |
COPY requirements.txt .
|
| 10 |
RUN pip install --no-cache-dir -r requirements.txt
|
|
|
|
| 5 |
# Install ffmpeg for audio processing
|
| 6 |
RUN apt-get update && apt-get install -y ffmpeg && apt-get clean
|
| 7 |
|
| 8 |
+
# Create a cache directory with proper permissions
|
| 9 |
+
RUN mkdir -p /app/.cache && chmod 777 /app/.cache
|
| 10 |
+
ENV TRANSFORMERS_CACHE=/app/.cache
|
| 11 |
+
ENV HF_HOME=/app/.cache
|
| 12 |
+
ENV SENTENCE_TRANSFORMERS_HOME=/app/.cache
|
| 13 |
+
|
| 14 |
# Install dependencies
|
| 15 |
COPY requirements.txt .
|
| 16 |
RUN pip install --no-cache-dir -r requirements.txt
|