1- FROM ubuntu:22.04
1+ FROM ubuntu:22.04 AS base
22
33RUN apt-get update && DEBIAN_FRONTEND=noninteractive apt-get install -y \
4+ build-essential \
5+ ca-certificates \
46 cmake \
7+ curl \
8+ cython3 \
9+ debhelper \
10+ dh-python \
511 g++-12 \
612 gfortran-12 \
713 git \
814 hdf5-tools \
9- liblapack-dev \
1015 libboost-dev \
1116 libfftw3-dev \
12- libnfft3-dev \
1317 libgfortran5 \
1418 libgmp-dev \
1519 libhdf5-dev \
20+ liblapack-dev \
21+ libnfft3-dev \
22+ libomp-dev \
1623 libopenmpi-dev \
17- cython3 \
24+ libpython3-dev \
1825 openmpi-bin \
1926 openmpi-common \
2027 openmpi-doc \
28+ openssl \
29+ pandoc \
30+ python-is-python3 \
31+ python3-ase \
32+ python3-decorator \
2133 python3-dev \
34+ python3-jinja2 \
2235 python3-mako \
23- python3-numpy \
24- python3-scipy \
2536 python3-matplotlib \
37+ python3-monty \
2638 python3-mpi4py \
27- python3-pip \
28- python3-sphinx \
39+ python3-myst-parser \
2940 python3-nbsphinx \
30- python3-skimage \
3141 python3-notebook \
32- libpython3-dev \
33- curl \
34- ca-certificates \
35- openssl \
36- wget \
42+ python3-numpy \
43+ python3-pip \
44+ python3-pytest \
45+ python3-scipy \
46+ python3-shapely \
47+ python3-skimage \
48+ python3-sphinx \
49+ python3-sphinx-rtd-theme \
3750 rsync \
38- libomp-dev \
3951 sudo \
40- nodejs \
41- npm \
4252 && \
4353 apt-get autoremove --purge -y && \
4454 apt-get autoclean -y && \
4555 rm -rf /var/cache/apt/* /var/lib/apt/lists/*
4656
47- RUN pip3 install --no-cache-dir \
48- cython \
49- decorator \
50- pytest \
51- shapely \
52- monty \
53- mpi4py \
54- Jinja2 \
55- Mako \
56- ase \
57- tornado \
58- zmq \
59- tk \
60- myst_parser \
61- sphinx_rtd_theme \
62- linkify-it-py \
63- Pandoc
57+ # linkify-it-py (required by sphinx doc build) is not available in Ubuntu 22.04 as package
58+ # the following manually installs it and its only dependency uc-micro-py
59+ RUN mkdir -p /src && cd /src \
60+ && curl -LOOO http://archive.ubuntu.com/ubuntu/pool/universe/u/uc-micro-py/uc-micro-py_1.0.1{-3.dsc,.orig.tar.xz,-3.debian.tar.xz} \
61+ && dpkg-source -x uc-micro-py_1.0.1-3.dsc \
62+ && cd uc-micro-py-1.0.1 \
63+ && DEB_BUILD_OPTIONS=nocheck dpkg-buildpackage -b -d -uc -us \
64+ && cd - \
65+ && apt-get install ./python3-uc-micro_1.0.1-3_all.deb \
66+ && curl -LOOO http://archive.ubuntu.com/ubuntu/pool/universe/l/linkify-it-py/linkify-it-py_2.0.0{-1.dsc,.orig.tar.gz,-1.debian.tar.xz} \
67+ && dpkg-source -x linkify-it-py_2.0.0-1.dsc \
68+ && cd linkify-it-py-2.0.0/ \
69+ && DEB_BUILD_OPTIONS=nocheck dpkg-buildpackage -b -d -uc -us \
70+ && cd - \
71+ && apt-get install ./python3-linkify-it_2.0.0-1_all.deb \
72+ && cd / && rm -rf /src
73+
74+ # the above is cached by the github action workflow
75+ FROM base AS pkgs
6476
6577ENV OMP_NUM_THREADS=1
6678ENV MKL_NUM_THREADS=1
@@ -81,6 +93,9 @@ ENV CPATH=/triqs/include:${CPATH} \
8193 LD_LIBRARY_PATH=/triqs/lib:${LD_LIBRARY_PATH} \
8294 PYTHONPATH=/triqs/lib/python3.10/site-packages:${PYTHONPATH} \
8395 CMAKE_PREFIX_PATH=/triqs/share/cmake:${CMAKE_PREFIX_PATH} \
96+ CMAKE_BUILD_PARALLEL_LEVEL=${NCORES} \
97+ CTEST_OUTPUT_ON_FAILURE=1 \
98+ CTEST_PARALLEL_LEVEL=${NCORES} \
8499 TRIQS_ROOT=/triqs
85100
86101RUN cd /source && git clone -b unstable --depth 1 https://github.com/TRIQS/triqs \
@@ -121,6 +136,3 @@ RUN cd /source && git clone -b unstable --depth 1 https://github.com/TRIQS/maxen
121136# remove source
122137RUN cd / && rm -rf source
123138
124- # make python3 default
125- RUN `ln -s /usr/bin/python3 /usr/bin/python`
126-
0 commit comments