Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Vega regular runs #69

Merged
merged 2 commits into from
Jul 17, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 48 additions & 0 deletions scripts/run_reframe.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
#!/bin/bash
# Author: Caspar van Leeuwen
# Description: This script can be used to do regular runs of the ReFrame test suite, e.g. from a cronjob.
#

# Configurable items
TEMPDIR=$(mktemp --directory --tmpdir=/tmp -t rfm.XXXXXXXXXX)
RFM_CONFIG_NAME=izum_vega.py
TAGS="-t 1_node|2_nodes"
GIT_PRIVATE_KEY="~/.ssh/id_github_ed25519" # Location of git private key, to be added to ssh-agent
# The hpctestlib as well as the reframe command will be based on this version
# May be adapted later to simply use reframe from the EESSI software stack
REFRAME_VERSION=4.2.1
REFRAME_VENV=reframe_421

# Add SSH key to agent, needed for git clone commands
eval "$(ssh-agent -s)"
ssh-add ${GIT_PRIVATE_KEY}

# Create virtualenv for ReFrame using system python
python3 -m venv ${TEMPDIR}/${REFRAME_VENV}
source ${TEMPDIR}/${REFRAME_VENV}/bin/activate
python3 -m pip install reframe-hpc==${REFRAME_VERSION}

# Clone reframe repo to have the hpctestlib:
git clone [email protected]:reframe-hpc/reframe.git --branch v${REFRAME_VERSION} ${TEMPDIR}/reframe
export PYTHONPATH=${PYTHONPATH}:${TEMPDIR}/reframe

# Clone test suite repo
git clone [email protected]:EESSI/test-suite.git ${TEMPDIR}/test-suite
export PYTHONPATH=${PYTHONPATH}:${TEMPDIR}/test-suite/

# Start the EESSI environment
unset MODULEPATH
source /cvmfs/pilot.eessi-hpc.org/latest/init/bash

# Needed in order to make sure the reframe from our TEMPDIR is first on the PATH,
# prior to the one shipped with the 2021.12 compat layer
# Probably no longer needed with newer compat layer that doesn't include ReFrame
deactivate
source ${TEMPDIR}/${REFRAME_VENV}/bin/activate

# Run ReFrame
echo "PYTHONPATH: ${PYTHONPATH}"
reframe -C ${TEMPDIR}/test-suite/config/${RFM_CONFIG_NAME} -c ${TEMPDIR}/test-suite/eessi/testsuite/tests/apps/ -R -t CI ${TAGS} -r

# Cleanup
rm -rf ${TEMPDIR}
12 changes: 12 additions & 0 deletions scripts/run_reframe_wrapper.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/bin/bash
# Author: Caspar van Leeuwen
# Description: wraps the run_reframe.sh script so that all stdout and stderr is easily be collected in a logfile

# logfile
mkdir -p ~/rfm_weekly_logs

datestamp=$(date +%Y%m%d_%H%M%S)
LOGFILE=~/rfm_weekly_logs/rfm_weekly_${datestamp}.log
touch $LOGFILE

~/run_reframe.sh > $LOGFILE 2>&1
Loading