Sparkonix commited on
Commit
1d2d19c
·
1 Parent(s): dcc3122

added cache env for HF

Browse files
Files changed (3) hide show
  1. .gitignore +4 -1
  2. Dockerfile +3 -0
  3. docker-compose.yml +1 -0
.gitignore CHANGED
@@ -44,4 +44,7 @@ env/
44
  .Spotlight-V100
45
  .Trashes
46
  ehthumbs.db
47
- Thumbs.db
 
 
 
 
44
  .Spotlight-V100
45
  .Trashes
46
  ehthumbs.db
47
+ Thumbs.db
48
+
49
+ # Ignore Hugging Face cache directory
50
+ .cache/huggingface/
Dockerfile CHANGED
@@ -16,6 +16,9 @@ ENV PORT=7860
16
  ENV MODEL_PATH="Sparkonix/email-classifier-model"
17
  # Replace YOUR_ACTUAL_USERNAME with your Hugging Face username after uploading the model
18
 
 
 
 
19
  # Expose the port
20
  EXPOSE 7860
21
 
 
16
  ENV MODEL_PATH="Sparkonix/email-classifier-model"
17
  # Replace YOUR_ACTUAL_USERNAME with your Hugging Face username after uploading the model
18
 
19
+ # Add this line to set cache location to a writable directory
20
+ ENV HF_HOME="/app/.cache/huggingface"
21
+
22
  # Expose the port
23
  EXPOSE 7860
24
 
docker-compose.yml CHANGED
@@ -9,4 +9,5 @@ services:
9
  - .:/app
10
  environment:
11
  - PORT=7860
 
12
  restart: unless-stopped
 
9
  - .:/app
10
  environment:
11
  - PORT=7860
12
+ - HF_HOME=/app/.cache/huggingface
13
  restart: unless-stopped