imseldrith commited on
Commit
2256d09
1 Parent(s): 6bda1de

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +13 -1
Dockerfile CHANGED
@@ -1,17 +1,29 @@
1
  FROM continuumio/miniconda3
2
 
 
3
  RUN apt update && apt install espeak-ng ffmpeg -y
4
 
 
5
  WORKDIR /root
6
 
 
7
  ADD ./requirements.txt .
8
  RUN pip install -r requirements.txt
9
 
 
10
  ADD ./src .
11
 
 
 
 
 
 
 
12
  # Ensure all files have appropriate permissions
13
  RUN chmod -R 755 /root
14
 
 
15
  RUN python -m nltk.downloader punkt
16
 
17
- CMD ["python", "main.py"]
 
 
1
  FROM continuumio/miniconda3
2
 
3
+ # Install necessary packages
4
  RUN apt update && apt install espeak-ng ffmpeg -y
5
 
6
+ # Set working directory
7
  WORKDIR /root
8
 
9
+ # Add requirements file and install dependencies
10
  ADD ./requirements.txt .
11
  RUN pip install -r requirements.txt
12
 
13
+ # Add source code
14
  ADD ./src .
15
 
16
+ # Create a writable cache directory
17
+ RUN mkdir -p /root/.cache/huggingface && chmod -R 777 /root/.cache
18
+
19
+ # Set environment variable for cache directory
20
+ ENV TRANSFORMERS_CACHE=/root/.cache/huggingface
21
+
22
  # Ensure all files have appropriate permissions
23
  RUN chmod -R 755 /root
24
 
25
+ # Download NLTK data
26
  RUN python -m nltk.downloader punkt
27
 
28
+ # Specify the command to run the application
29
+ CMD ["python", "main.py"]