-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
75 lines (68 loc) · 2.73 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
FROM python:3.9-slim-buster
ARG VERSION="0.0.4"
ARG SIMULATOR_VERSION="1.0.2"
# metadata
LABEL \
org.opencontainers.image.title="RBApy" \
org.opencontainers.image.version="${SIMULATOR_VERSION}" \
org.opencontainers.image.description="Package for automated generation of bacterial Resource Balance Analysis (RBA) models and simulation of RBA models" \
org.opencontainers.image.url="https://sysbioinra.github.io/RBApy/" \
org.opencontainers.image.documentation="https://sysbioinra.github.io/RBApy/" \
org.opencontainers.image.source="https://github.com/biosimulators/Biosimulators_RBApy" \
org.opencontainers.image.authors="BioSimulators Team <[email protected]>" \
org.opencontainers.image.vendor="BioSimulators Team" \
org.opencontainers.image.licenses="GPL-3.0-or-later" \
\
base_image="python:3.9-slim-buster" \
version="${VERSION}" \
software="RBApy" \
software.version="${SIMULATOR_VERSION}" \
about.summary="Package for automated generation of bacterial Resource Balance Analysis (RBA) models and simulation of RBA models" \
about.home="https://sysbioinra.github.io/RBApy/" \
about.documentation="https://sysbioinra.github.io/RBApy/" \
about.license_file="https://github.com/SysBioInra/RBApy/blob/master/LICENSE.txt" \
about.license="SPDX:GPL-3.0-or-later" \
about.tags="systems biology,biochemical networks,Resource Balance Analysis,RBA,SED-ML,COMBINE,OMEX,BioSimulators" \
maintainer="BioSimulators Team <[email protected]>"
# Install GLPK
RUN apt-get update -y \
&& apt-get install -y --no-install-recommends \
gcc \
libglpk-dev \
&& pip install glpk \
&& apt-get remove -y \
gcc \
&& apt-get autoremove -y \
&& rm -rf /var/lib/apt/lists/*
# fonts for matplotlib
RUN apt-get update -y \
&& apt-get install -y --no-install-recommends libfreetype6 \
&& rm -rf /var/lib/apt/lists/*
# Install RBApy
RUN apt-get update -y \
&& apt-get install -y --no-install-recommends \
git \
\
&& cd /tmp \
&& git clone https://github.com/biosimulators/RBApy.git \
&& pip install RBApy/[glpk,gurobi] \
\
&& rm -r RBApy \
&& apt-get remove -y \
git \
&& apt-get autoremove -y \
&& rm -rf /var/lib/apt/lists/*
# Copy code for command-line interface into image and install it
COPY . /root/Biosimulators_RBApy
RUN pip install /root/Biosimulators_RBApy[glpk,gurobi] \
&& rm -rf /root/Biosimulators_RBApy
ENV VERBOSE=0 \
MPLBACKEND=PDF
RUN mkdir -p /.config/matplotlib \
&& mkdir -p /.cache/matplotlib \
&& chmod ugo+rw /.config/matplotlib \
&& chmod ugo+rw /.cache/matplotlib \
&& python -c "import matplotlib.font_manager"
# Entrypoint
ENTRYPOINT ["biosimulators-rbapy"]
CMD []