Skip to content

Commit

Permalink
improvements to resuming job environment
Browse files Browse the repository at this point in the history
  • Loading branch information
truib committed Feb 7, 2023
1 parent 8e2f09c commit 23e773c
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 7 deletions.
10 changes: 5 additions & 5 deletions bot/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ REPOSITORY_OPT=
if [[ ! -z ${REPOSITORY} ]]; then
REPOSITORY_OPT="--repository ${REPOSITORY}"
fi
mkdir -p previous_tmp
mkdir -p previous_tmp/{build_step,tarball_step}
build_outerr=$(mktemp build.outerr.XXXX)
echo "Executing command to build software:"
echo "./eessi_container.sh --access rw"
Expand All @@ -151,7 +151,7 @@ echo " ${HTTPS_PROXY_OPT}"
echo " --info"
echo " --mode run"
echo " ${REPOSITORY_OPT}"
echo " --save ${PWD}/previous_tmp"
echo " --save ${PWD}/previous_tmp/build_step"
echo " --storage ${STORAGE}"
echo " ./install_software_layer.sh \"$@\" 2>&1 | tee -a ${build_outerr}"
# set EESSI_REPOS_CFG_DIR_OVERRIDE to ./cfg
Expand All @@ -163,7 +163,7 @@ export EESSI_REPOS_CFG_DIR_OVERRIDE=${PWD}/cfg
--info \
--mode run \
${REPOSITORY_OPT} \
--save ${PWD}/previous_tmp \
--save ${PWD}/previous_tmp/build_step \
--storage ${STORAGE} \
./install_software_layer.sh "$@" 2>&1 | tee -a ${build_outerr}

Expand All @@ -190,7 +190,7 @@ echo " --info"
echo " --mode run"
echo " ${REPOSITORY_OPT}"
echo " --resume ${BUILD_TMPDIR}"
echo " --save ${PWD}/previous_tmp"
echo " --save ${PWD}/previous_tmp/tarball_step"
echo " ./create_tarball.sh ${TMP_IN_CONTAINER} ${EESSI_PILOT_VERSION} ${EESSI_SOFTWARE_SUBDIR_OVERRIDE} /eessi_bot_job/${TGZ} 2>&1 | tee -a ${tar_outerr}"
./eessi_container.sh --access rw \
${CONTAINER_OPT} \
Expand All @@ -200,7 +200,7 @@ echo " ./create_tarball.sh ${TMP_IN_CONTAINER} ${EESSI_PILOT
--mode run \
${REPOSITORY_OPT} \
--resume ${BUILD_TMPDIR} \
--save ${PWD}/previous_tmp \
--save ${PWD}/previous_tmp/tarball_step \
./create_tarball.sh ${TMP_IN_CONTAINER} ${EESSI_PILOT_VERSION} ${EESSI_SOFTWARE_SUBDIR_OVERRIDE} /eessi_bot_job/${TGZ} 2>&1 | tee -a ${tar_outerr}

exit 0
7 changes: 5 additions & 2 deletions eessi_container.sh
Original file line number Diff line number Diff line change
Expand Up @@ -354,6 +354,9 @@ else
# standard EESSI repositories)
cfg_load ${EESSI_REPOS_CFG_FILE}

# copy repos.cfg to job directory --> makes it easier to inspect the job
cp ${EESSI_REPOS_CFG_FILE} ${EESSI_TMPDIR}/repos_cfg/.

# cfg file should include: repo_name, repo_version, config_bundle,
# map { local_filepath -> container_filepath }
#
Expand Down Expand Up @@ -487,8 +490,8 @@ if [ ! -z ${EESSI_SOFTWARE_SUBDIR_OVERRIDE} ]; then
export APPTAINERENV_EESSI_SOFTWARE_SUBDIR_OVERRIDE=${EESSI_SOFTWARE_SUBDIR_OVERRIDE}
fi

# if INFO is set to 0 (no arg --info), add argument '-q'
if [[ ${INFO} -eq 0 ]]; then
# if INFO is set to 1 (arg --info), add argument '-q'
if [[ -z ${INFO} ]]; then
RUN_QUIET='-q'
else
RUN_QUIET=''
Expand Down

0 comments on commit 23e773c

Please sign in to comment.