Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updating Dockerfile and correcting bugs #26

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,14 +1,20 @@
FROM python:3
FROM python:3.9.6-bullseye

#Update the image we start from and install all latex stuf and dependencies for mupdf
RUN apt-get update -y\
&& apt-get install texlive-full -y\
&& apt-get install graphviz -y\
&& apt-get install libx11-dev mesa-common-dev libgl1-mesa-dev -y\
&& rm -rf /var/lib/apt/lists/*


#Copy varylatex files to the image
COPY . /varylatex
WORKDIR /varylatex

#Install mupdf 1.18.16 version
RUN sh mupdf_install.sh

#Install varylatex python dependencies
RUN pip install -r requirements.txt

VOLUME /varylatex/build
Expand Down
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ You can also run the app within a `Docker` container : to do this, install docke
sudo docker build -t varylatex .
# Create the container
sudo docker run -it --rm -p 5000:5000 varylatex
# In case you want to rely on a prebuild image there is one at https://hub.docker.com/r/diversolab/varylatex
```
And inside the container you can run
```bash
Expand Down
7 changes: 7 additions & 0 deletions mupdf_install.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#\bin\sh
wget -O mupdf.tar.gz https://mupdf.com/downloads/archive/mupdf-1.18.0-source.tar.gz ;
tar -xzf mupdf.tar.gz
ls
cd mupdf-1.18.0-source
make
make HAVE_X11=no HAVE_GLUT=no prefix=/usr/local install
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Flask==1.1.2
intervaltree==3.0.2
PyMuPDF==1.17.1
PyMuPDF==1.18.16
pandas==1.0.5
requests==2.22.0
scikit-learn==0.23.1