maahi2412 commited on
Commit
f9962bc
·
verified ·
1 Parent(s): 4756959

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +8 -1
Dockerfile CHANGED
@@ -31,7 +31,7 @@ FROM python:3.8-slim
31
  # Set working directory
32
  WORKDIR /app
33
 
34
- # Install system dependencies (e.g., for pdfplumber, pytesseract)
35
  RUN apt-get update && apt-get install -y \
36
  tesseract-ocr \
37
  libtesseract-dev \
@@ -55,6 +55,13 @@ RUN pip install --no-cache-dir \
55
  scikit-learn \
56
  gunicorn
57
 
 
 
 
 
 
 
 
58
  # Expose port
59
  EXPOSE 5000
60
 
 
31
  # Set working directory
32
  WORKDIR /app
33
 
34
+ # Install system dependencies
35
  RUN apt-get update && apt-get install -y \
36
  tesseract-ocr \
37
  libtesseract-dev \
 
55
  scikit-learn \
56
  gunicorn
57
 
58
+ # Create uploads and cache directories with proper permissions
59
+ RUN mkdir -p /app/uploads /app/cache && \
60
+ chmod -R 777 /app/uploads /app/cache
61
+
62
+ # Set environment variable for Hugging Face cache
63
+ ENV TRANSFORMERS_CACHE=/app/cache
64
+
65
  # Expose port
66
  EXPOSE 5000
67