freddyaboulton HF staff commited on
Commit
afaacad
1 Parent(s): c799e0a

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +6 -1
Dockerfile CHANGED
@@ -1,4 +1,3 @@
1
-
2
  FROM python:3.9
3
 
4
  WORKDIR /code
@@ -7,6 +6,12 @@ COPY --link --chown=1000 . .
7
 
8
  RUN pip install --no-cache-dir -r requirements.txt
9
 
 
 
 
 
 
 
10
  ENV PYTHONUNBUFFERED=1 GRADIO_ALLOW_FLAGGING=never GRADIO_NUM_PORTS=1 GRADIO_SERVER_NAME=0.0.0.0 GRADIO_SERVER_PORT=7860 SYSTEM=spaces
11
 
12
  CMD ["python", "app.py"]
 
 
1
  FROM python:3.9
2
 
3
  WORKDIR /code
 
6
 
7
  RUN pip install --no-cache-dir -r requirements.txt
8
 
9
+ RUN mkdir -p /tmp/cache/
10
+ RUN chmod a+rwx -R /tmp/cache/
11
+
12
+ RUN apt-get update && apt-get install -y poppler-utils tesseract-ocr chromium
13
+
14
+ ENV TRANSFORMERS_CACHE=/tmp/cache/
15
  ENV PYTHONUNBUFFERED=1 GRADIO_ALLOW_FLAGGING=never GRADIO_NUM_PORTS=1 GRADIO_SERVER_NAME=0.0.0.0 GRADIO_SERVER_PORT=7860 SYSTEM=spaces
16
 
17
  CMD ["python", "app.py"]