EladSpamson commited on
Commit
57b876b
·
verified ·
1 Parent(s): aefce6b

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +3 -4
Dockerfile CHANGED
@@ -1,6 +1,6 @@
1
  FROM python:3.10-slim
2
 
3
- # Environment variable overrides, so HF never attempts to write to /.cache
4
  ENV HF_HOME=/tmp/hf_cache
5
  ENV TRANSFORMERS_CACHE=/tmp/hf_cache
6
  ENV HF_DATASETS_CACHE=/tmp/hf_cache
@@ -9,13 +9,12 @@ ENV XDG_CACHE_HOME=/tmp
9
  WORKDIR /app
10
  COPY . /app
11
 
12
- # Install apt packages for audio decoding (WAV, MP3, FLAC, etc.)
13
  RUN apt-get update && apt-get install -y ffmpeg libsndfile1 && rm -rf /var/lib/apt/lists/*
14
 
15
- # Install Python dependencies
16
  RUN pip install --no-cache-dir -r requirements.txt
17
 
18
- # Extend Gunicorns default 30s timeout 5 minutes
19
  ENV GUNICORN_CMD_ARGS="--timeout 300 --workers=1"
20
 
21
  EXPOSE 7860
 
1
  FROM python:3.10-slim
2
 
3
+ # Environment variable overrides
4
  ENV HF_HOME=/tmp/hf_cache
5
  ENV TRANSFORMERS_CACHE=/tmp/hf_cache
6
  ENV HF_DATASETS_CACHE=/tmp/hf_cache
 
9
  WORKDIR /app
10
  COPY . /app
11
 
12
+ # Install apt packages for audio decoding (MP3, WAV, etc.)
13
  RUN apt-get update && apt-get install -y ffmpeg libsndfile1 && rm -rf /var/lib/apt/lists/*
14
 
 
15
  RUN pip install --no-cache-dir -r requirements.txt
16
 
17
+ # Increase Gunicorn's timeout (300s) for bigger files
18
  ENV GUNICORN_CMD_ARGS="--timeout 300 --workers=1"
19
 
20
  EXPOSE 7860