software-layer icon indicating copy to clipboard operation
software-layer copied to clipboard

use directory of called script as base dir for other scripts

Open trz42 opened this issue 1 year ago • 4 comments

This improves the usability of bot/inspect.sh / fixes a bug. If one ran the script from another directory as the working directory of a bot job (or the main directory of a checkout of EESSI/software-layer), it fails to source other scripts and does not find ./eessi_container.sh.

trz42 avatar May 16 '24 10:05 trz42

Instance eessi-bot-mc-aws is configured to build:

  • arch x86_64/generic for repo eessi-hpc.org-2023.06-compat
  • arch x86_64/generic for repo eessi-hpc.org-2023.06-software
  • arch x86_64/generic for repo eessi.io-2023.06-compat
  • arch x86_64/generic for repo eessi.io-2023.06-software
  • arch x86_64/intel/haswell for repo eessi-hpc.org-2023.06-compat
  • arch x86_64/intel/haswell for repo eessi-hpc.org-2023.06-software
  • arch x86_64/intel/haswell for repo eessi.io-2023.06-compat
  • arch x86_64/intel/haswell for repo eessi.io-2023.06-software
  • arch x86_64/intel/skylake_avx512 for repo eessi-hpc.org-2023.06-compat
  • arch x86_64/intel/skylake_avx512 for repo eessi-hpc.org-2023.06-software
  • arch x86_64/intel/skylake_avx512 for repo eessi.io-2023.06-compat
  • arch x86_64/intel/skylake_avx512 for repo eessi.io-2023.06-software
  • arch x86_64/amd/zen2 for repo eessi-hpc.org-2023.06-compat
  • arch x86_64/amd/zen2 for repo eessi-hpc.org-2023.06-software
  • arch x86_64/amd/zen2 for repo eessi.io-2023.06-compat
  • arch x86_64/amd/zen2 for repo eessi.io-2023.06-software
  • arch x86_64/amd/zen3 for repo eessi-hpc.org-2023.06-compat
  • arch x86_64/amd/zen3 for repo eessi-hpc.org-2023.06-software
  • arch x86_64/amd/zen3 for repo eessi.io-2023.06-compat
  • arch x86_64/amd/zen3 for repo eessi.io-2023.06-software
  • arch aarch64/generic for repo eessi-hpc.org-2023.06-compat
  • arch aarch64/generic for repo eessi-hpc.org-2023.06-software
  • arch aarch64/generic for repo eessi.io-2023.06-compat
  • arch aarch64/generic for repo eessi.io-2023.06-software
  • arch aarch64/neoverse_n1 for repo eessi-hpc.org-2023.06-compat
  • arch aarch64/neoverse_n1 for repo eessi-hpc.org-2023.06-software
  • arch aarch64/neoverse_n1 for repo eessi.io-2023.06-compat
  • arch aarch64/neoverse_n1 for repo eessi.io-2023.06-software
  • arch aarch64/neoverse_v1 for repo eessi-hpc.org-2023.06-compat
  • arch aarch64/neoverse_v1 for repo eessi-hpc.org-2023.06-software
  • arch aarch64/neoverse_v1 for repo eessi.io-2023.06-compat
  • arch aarch64/neoverse_v1 for repo eessi.io-2023.06-software

eessi-bot[bot] avatar May 16 '24 10:05 eessi-bot[bot]

Instance eessi-bot-mc-azure is configured to build:

  • arch x86_64/amd/zen4 for repo eessi-hpc.org-2023.06-compat
  • arch x86_64/amd/zen4 for repo eessi-hpc.org-2023.06-software
  • arch x86_64/amd/zen4 for repo eessi.io-2023.06-compat
  • arch x86_64/amd/zen4 for repo eessi.io-2023.06-software

eessi-bot[bot] avatar May 16 '24 10:05 eessi-bot[bot]

Line 260 in this file should be updated to keep things consistent

https://github.com/trz42/software-layer/blob/use_full_path_in_inspect_script/bot/inspect.sh#L258-L263

Updated the script by using a single variable (and only setting its value once). Also changed variable name from uppercase to lowercase.

trz42 avatar May 16 '24 15:05 trz42

Changes look good, but I'm not sure how to test this, if I try to submit a build job I guess it will run...

You can use this to inspect a build job by:

  1. launching an interactive job on a node with the same architecture as was used by the build job
  2. determine the working directory of the build job you want to inspect, say BUILD_JOB_DIR
  3. then run $BUILD_JOB_DIR/bot/inspect.sh --resume $BUILD_JOB_DIR/previous_tmp/build_step/eessi...tgz

(I think, it should be possible to create a tool/script that does all three steps, such that you could just run debug_session.sh --job-id SLURM_JOBID or similar. Thus it would become even easier to debug failing jobs.)

trz42 avatar May 16 '24 15:05 trz42