Skip to content

Commit

Permalink
Docker: Restore Fedora test which got lost in 7b909a0
Browse files Browse the repository at this point in the history
  • Loading branch information
oschuett committed Jul 31, 2023
1 parent de16073 commit a86c0e5
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
10 changes: 6 additions & 4 deletions tools/docker/Dockerfile.test_fedora-psmp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ COPY ./tools/toolchain/scripts/VERSION \
COPY ./tools/toolchain/install_cp2k_toolchain.sh .
RUN ./install_cp2k_toolchain.sh \
--install-all \
--mpi-mode=mpich \
--with-gcc=system \
--dry-run

Expand Down Expand Up @@ -71,20 +70,23 @@ RUN /bin/bash -c " \
ln -vs /opt/cp2k-toolchain/install/arch/local.psmp ./arch/ && \
echo 'Compiling cp2k...' && \
source /opt/cp2k-toolchain/install/setup && \
( make -j ARCH=local VERSION=psmp &> /dev/null || true )"
( make -j ARCH=local VERSION=psmp &> /dev/null || true ) && \
rm -rf lib obj && \
( [ ! -f ./exe/local/cp2k.psmp ] || ldd ./exe/local/cp2k.psmp | grep -q libmpi )"
COPY ./data ./data
COPY ./tests ./tests
COPY ./tools/regtesting ./tools/regtesting

# Run regression tests.
ARG TESTOPTS
ARG TESTOPTS=""
COPY ./tools/docker/scripts/test_regtest.sh ./
RUN /bin/bash -c " \
RUN /bin/bash -o pipefail -c " \
TESTOPTS="${TESTOPTS}" \
./test_regtest.sh 'local' 'psmp' |& tee report.log && \
rm -rf regtesting"

# Output the report if the image is old and was therefore pulled from the build cache.
CMD cat $(find ./report.log -mmin +10) | sed '/^Summary:/ s/$/ (cached)/'
ENTRYPOINT []

#EOF
3 changes: 3 additions & 0 deletions tools/docker/generate_dockerfiles.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@ def main() -> None:
f.write(toolchain_full(mpi_mode="openmpi", with_gcc="install"))
f.write(regtest("psmp"))

with OutputFile(f"Dockerfile.test_fedora-psmp", args.check) as f:
f.write(toolchain_full(base_image="fedora:33") + regtest("psmp"))

with OutputFile(f"Dockerfile.test_intel-psmp", args.check) as f:
f.write(toolchain_intel() + regtest("psmp", intel=True))

Expand Down

0 comments on commit a86c0e5

Please sign in to comment.