Skip to content

Commit

Permalink
Docker: Make OpenMPI happy
Browse files Browse the repository at this point in the history
  • Loading branch information
oschuett committed Jul 3, 2019
1 parent 069824f commit 25db5e7
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
10 changes: 8 additions & 2 deletions tools/docker/scripts/install_regtest.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,12 @@ ln -vs /opt/cp2k-toolchain/install/arch/local* .
# shellcheck disable=SC1091
source /opt/cp2k-toolchain/install/setup

# Make OpenMPI happy.
if which ompi_info &> /dev/null ; then
TESTOPTS="-mpiexec 'mpiexec --bind-to none --allow-run-as-root' ${TESTOPTS}"
export OMPI_MCA_plm_rsh_agent=/bin/false
fi

# pre-build cp2k
cd /workspace/cp2k
echo -n "Warming cache by trying to compile... "
Expand All @@ -26,12 +32,12 @@ else
echo "failed."
fi


# run regtests which lack fixed reference value
# Disable LeakSanitizer during docker build as it requires ptrace capabilities.
export LSAN_OPTIONS="detect_leaks=0"

echo -n "Trying to run regtests which lack reference values... "
if make test ARCH="${ARCH}" VERSION="${VERSION}" TESTOPTS="-restrictdir QS/regtest-almo-md -restrictdir QS/regtest-almo-1 -restrictdir SE/regtest-3-4 -restrictdir QS/regtest-ot-1-vib -restrictdir Fist/regtest-5-vib -restrictdir QS/regtest-optbas -restrictdir TMC/regtest_ana_post_proc" &> /dev/null ; then
if make test ARCH="${ARCH}" VERSION="${VERSION}" TESTOPTS="${TESTOPTS} -restrictdir QS/regtest-almo-md -restrictdir QS/regtest-almo-1 -restrictdir SE/regtest-3-4 -restrictdir QS/regtest-ot-1-vib -restrictdir Fist/regtest-5-vib -restrictdir QS/regtest-optbas -restrictdir TMC/regtest_ana_post_proc" &> /dev/null ; then
echo "done."
else
echo "failed."
Expand Down
6 changes: 6 additions & 0 deletions tools/docker/scripts/test_regtest.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ VERSION=$2
# shellcheck disable=SC1091
source /opt/cp2k-toolchain/install/setup

# Make OpenMPI happy.
if which ompi_info &> /dev/null ; then
TESTOPTS="-mpiexec 'mpiexec --bind-to none --allow-run-as-root' ${TESTOPTS}"
export OMPI_MCA_plm_rsh_agent=/bin/false
fi

echo -e "\n========== Running Regtests =========="
cd /workspace/cp2k
make ARCH="${ARCH}" VERSION="${VERSION}" TESTOPTS="${TESTOPTS}" test
Expand Down

0 comments on commit 25db5e7

Please sign in to comment.