leonarb commited on
Commit
d641974
·
verified ·
1 Parent(s): 243af33

Create Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +26 -0
Dockerfile ADDED
@@ -0,0 +1,26 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ FROM ubuntu:20.04
2
+
3
+ # Install dependencies
4
+ RUN apt-get update && apt-get install -y \
5
+ wget build-essential cmake git g++ pkg-config libfontforge-dev \
6
+ fontforge libpoppler-glib-dev poppler-utils \
7
+ libpng-dev libjpeg-dev libtiff-dev \
8
+ zlib1g-dev libfreetype6-dev libxrender-dev \
9
+ libxml2-dev libspiro-dev python3 python3-pip && \
10
+ apt-get clean
11
+
12
+ # Clone and build pdf2htmlEX
13
+ RUN git clone https://github.com/coolwanglu/pdf2htmlEX.git && \
14
+ cd pdf2htmlEX && \
15
+ cmake . && \
16
+ make && \
17
+ make install
18
+
19
+ # Install Python dependencies
20
+ COPY requirements.txt .
21
+ RUN pip3 install -r requirements.txt
22
+
23
+ # Copy app
24
+ COPY app.py .
25
+
26
+ CMD ["python3", "app.py"]