Spaces:
Sleeping
Sleeping
Update Dockerfile
Browse files- Dockerfile +7 -3
Dockerfile
CHANGED
@@ -13,13 +13,17 @@ RUN pip install --no-cache-dir -r requirements.txt
|
|
13 |
# Copy the current directory contents into the container at /app
|
14 |
COPY . /app
|
15 |
|
16 |
-
# Create the logs
|
17 |
RUN mkdir -p /app/logs && chmod -R 777 /app/logs
|
|
|
|
|
|
|
|
|
18 |
|
19 |
# Download NLTK data
|
20 |
-
RUN python -c "import nltk; nltk.download('stopwords'); nltk.download('wordnet')"
|
21 |
|
22 |
-
# Make port
|
23 |
EXPOSE 7860
|
24 |
|
25 |
# Run the entrypoint script
|
|
|
13 |
# Copy the current directory contents into the container at /app
|
14 |
COPY . /app
|
15 |
|
16 |
+
# Create the logs and nltk_data directories and set permissions
|
17 |
RUN mkdir -p /app/logs && chmod -R 777 /app/logs
|
18 |
+
RUN mkdir -p /app/nltk_data && chmod -R 777 /app/nltk_data
|
19 |
+
|
20 |
+
# Set the NLTK_DATA environment variable
|
21 |
+
ENV NLTK_DATA=/app/nltk_data
|
22 |
|
23 |
# Download NLTK data
|
24 |
+
RUN python -c "import nltk; nltk.download('stopwords', download_dir='/app/nltk_data'); nltk.download('wordnet', download_dir='/app/nltk_data')"
|
25 |
|
26 |
+
# Make port 7860 available to the world outside this container
|
27 |
EXPOSE 7860
|
28 |
|
29 |
# Run the entrypoint script
|