I have a SLURM (v19.05.6) batch script :
test.sh :
#!/bin/bash
#SBATCH --mail-user=First.Last@domain.com
#SBATCH --mail-type=ALL
env
Within my script, I'd like to be able to get email address (i.e. First.Last@domain.com) that SLURM uses to mail the user. I printed out the environment (i.e. env) and it is not set as an environmental variable. Looking at the man page for sacct doesn't contain a field for email address either.
QUESTION :
How do I get the email address used by SLURM to email users? In my use case, I'd like to capture that email address and use it in subsequently spawned jobs.