Spaces:
Sleeping
Sleeping
Update Dockerfile
Browse files- Dockerfile +7 -0
Dockerfile
CHANGED
|
@@ -3,6 +3,13 @@ FROM python:3.9-slim
|
|
| 3 |
# Set working directory
|
| 4 |
WORKDIR /app
|
| 5 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 6 |
# Copy requirements file
|
| 7 |
COPY requirements.txt .
|
| 8 |
|
|
|
|
| 3 |
# Set working directory
|
| 4 |
WORKDIR /app
|
| 5 |
|
| 6 |
+
# Create a cache directory and set permissions
|
| 7 |
+
RUN mkdir -p /app/cache && chmod -R 777 /app/cache
|
| 8 |
+
|
| 9 |
+
# Set environment variable for Hugging Face cache
|
| 10 |
+
ENV TRANSFORMERS_CACHE=/app/cache
|
| 11 |
+
ENV HF_HOME=/app/cache
|
| 12 |
+
|
| 13 |
# Copy requirements file
|
| 14 |
COPY requirements.txt .
|
| 15 |
|