samdak93 commited on
Commit
22a3c8a
·
1 Parent(s): ad184b5

chnage dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -3
Dockerfile CHANGED
@@ -10,16 +10,19 @@ RUN apt-get update && apt-get install -y \
10
  python3-dev \
11
  && rm -rf /var/lib/apt/lists/*
12
 
13
- # Set environment variable to avoid permission errors
14
  ENV TRANSFORMERS_CACHE=/app/cache
15
  ENV HF_HOME=/app/cache
16
 
 
 
 
 
17
  # Copy app code
18
  COPY app.py /app/app.py
19
  COPY requirements.txt /app/requirements.txt
20
 
21
- # Create the cache directory
22
- RUN mkdir -p /app/cache
23
 
24
  # Install Python dependencies
25
  RUN pip install --upgrade pip && pip install -r requirements.txt
 
10
  python3-dev \
11
  && rm -rf /var/lib/apt/lists/*
12
 
13
+ # Make sure you set the environment variables
14
  ENV TRANSFORMERS_CACHE=/app/cache
15
  ENV HF_HOME=/app/cache
16
 
17
+ # Create the writable directory for cache
18
+ RUN mkdir -p /app/cache
19
+
20
+
21
  # Copy app code
22
  COPY app.py /app/app.py
23
  COPY requirements.txt /app/requirements.txt
24
 
25
+
 
26
 
27
  # Install Python dependencies
28
  RUN pip install --upgrade pip && pip install -r requirements.txt