Skip to content

Commit

Permalink
"rebasing with cp" the CI of pycv
Browse files Browse the repository at this point in the history
  • Loading branch information
Iximiel committed Dec 6, 2023
1 parent be86709 commit 47fa0e9
Show file tree
Hide file tree
Showing 6 changed files with 70 additions and 13 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/dockerWF.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,6 @@ jobs:
- name: Build and run tests
run: |
make -C docker ${{ matrix.variant }}
- name: PyCV tests
run: |
make -C docker ${{ matrix.variant }}-pycv
12 changes: 11 additions & 1 deletion .github/workflows/linuxWF.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ jobs:
# temporarily commented out
# see https://github.com/plumed/plumed2/issues/976
- -intel-
- -pycv-mpi-
steps:
- uses: actions/checkout@v4
- uses: actions/cache@v3
Expand Down Expand Up @@ -152,7 +153,7 @@ jobs:
make nmcheck
ccache -s -M 100M
- name: Run tests
if: ${{ ! contains( matrix.variant, '-doc-mpi-' ) }}
if: ${{ ! contains( matrix.variant, '-doc-mpi-' ) && ! contains( matrix.variant, '-pycv-mpi-' ) }}
run: |
(while true; do # see https://github.com/actions/virtual-environments/issues/1860
df -h
Expand Down Expand Up @@ -185,3 +186,12 @@ jobs:
GIT_TOKEN: ${{ secrets.GIT_TOKEN_PLUMEDBOT }}
run: |
.ci/push doc
- name: Compile and test pycv
if: contains( matrix.variant, '-pycv-' )
working-directory: ./plugins/pycv/
run: |
pip install --user pybind11
source ../../sourceme.sh
ln -s $(realpath ../../regtest/scripts) ./regtest/scripts
./prepareMakeForDevelop.sh
make check
14 changes: 10 additions & 4 deletions docker/Makefile
Original file line number Diff line number Diff line change
@@ -1,14 +1,20 @@

.PHONY: ubuntu plumed2.tgz clean fedora39 rocky8
.PHONY: ubuntu plumed2.tgz clean fedora39 fedora39-pycv rocky8 rocky8-pycv

ubuntu: plumed2.tgz
docker build -t plumed .
docker build -t plumed --progress=plain .

fedora39: plumed2.tgz
docker build -t plumed -f fedora39 .
docker build -t plumed:fedora39 --progress=plain -f fedora39 .
fedora39-pycv: plumed2.tgz
docker build -t plumed:fedora39-pycv --progress=plain -f fedora39-pycv .


rocky8: plumed2.tgz
docker build -t plumed -f rocky8 .
docker build -t plumed:rocky8 --progress=plain -f rocky8 .

rocky8-pycv: plumed2.tgz
docker build -t plumed:rocky8-pycv --progress=plain -f rocky8-pycv .

plumed2.tgz:
cd ../ ; git archive HEAD -o "$(CURDIR)"/plumed2.tgz --prefix plumed2/ ; cd -
Expand Down
11 changes: 11 additions & 0 deletions docker/fedora39-pycv
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
FROM plumed:fedora39

RUN source /etc/bashrc \
&& module load mpi \
&& cd plumed2 \
&& source ./sourceme.sh \
&& cd plugins/pycv \
&& pip3 install pybind11 \
&& ln -s $(realpath ../../regtest/scripts) ./regtest/scripts \
&& ./prepareMakeForDevelop.sh \
&& make check
32 changes: 24 additions & 8 deletions docker/rocky8
Original file line number Diff line number Diff line change
Expand Up @@ -7,23 +7,40 @@ RUN yum -y update \
&& dnf config-manager --set-enabled powertools \
&& yum -y group install "Development Tools" \
&& yum -y install environment-modules gawk vim wget \
lapack-devel blas-devel zlib-devel gsl-devel fftw-devel openmpi-devel boost-devel \
python3 python3-devel python3-pip \
&& pip3 install pillow==8.3.2 \
&& pip3 install numpy==1.19 \
&& pip3 install "cython<3" numpy pandas mdtraj \
&& pip3 install MDAnalysis==1.0.0
lapack-devel blas-devel zlib-devel gsl-devel fftw-devel openmpi-devel boost-devel \
openssl-devel libffi-devel

RUN useradd -ms /bin/bash plumed
#These are needed for installing python

USER plumed
WORKDIR /home/plumed

#Install python with --embedded enabled
RUN PYVERSION="3.9.16" \
&& curl -LO https://www.python.org/ftp/python/${PYVERSION}/Python-${PYVERSION}.tgz \
&& tar xzf Python-${PYVERSION}.tgz \
&& cd Python-${PYVERSION} \
&& ./configure --enable-shared --prefix=$HOME/.local \
&& make -j 4 \
&& make install \
&& echo "export LD_LIBRARY_PATH=$HOME/.local/lib/${LD_LIBRARY_PATH:+:}${LD_LIBRARY_PATH}" >> "$HOME/.bashrc"

RUN . ./.bashrc \
&& pip3 install --user -U pip \
&& pip3 install --user pillow==8.3.2 \
&& pip3 install --user "Cython<3" \
&& pip3 install --user pandas \
&& pip3 install --user mdtraj \
&& pip3 install --user MDAnalysis==1.0.0
# && pip3 install --user numpy==1.19

# import plumed code.
# assumes a file plumed2.tgz is present in the Dockerfile directory
COPY plumed2.tgz /home/plumed

# build and test plumed (no install)
RUN . /etc/bashrc \
RUN . ./.bashrc \
&& module load mpi \
&& export OMPI_MCA_btl_base_warn_component_unused=0 \
&& export OMPI_MCA_btl_base_verbose=0 \
Expand All @@ -42,4 +59,3 @@ RUN . /etc/bashrc \
&& ./configure --enable-modules=all --enable-boost_serialization \
&& make -j 4 \
&& make check

11 changes: 11 additions & 0 deletions docker/rocky8-pycv
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
FROM plumed:rocky8

RUN source ./.bashrc \
&& module load mpi \
&& cd plumed2 \
&& source ./sourceme.sh \
&& cd plugins/pycv \
&& pip3 install --user pybind11 \
&& ln -s $(realpath ../../regtest/scripts) ./regtest/scripts \
&& ./prepareMakeForDevelop.sh \
&& make check

0 comments on commit 47fa0e9

Please sign in to comment.