ramya ranaganathan
09/12/2025, 10:53 AMThomas Danhorn
09/13/2025, 1:43 AMexport NXF_TEMP=/path/to/your/scratch (e.g. in the script that starts the pipeline, or in your shell)?
A "nuclear option" to by-pass /tmp would be bind-mounting your scratch with Singularity:
singularity {
runOptions = "-B /path/to/yout/scratch:/tmp"
}
(put that in a config file to use with -c)
Note that the ucl_myriad profile already has this:
singularity {
// other stuff ...
runOptions = "-B ${HOME},${PWD} --no-mount /scratch --writable-tmpfs"
}
I'm not sure if all that is necessary, if if some of it is, you may have to add it to your runOptions.
You could also talk to your sysadmins and see what they want you to do. 🤞pontus
09/14/2025, 6:21 PMpontus
09/14/2025, 6:25 PMucl_myriad profile already having that, I'm not sure what Thomas means there.pontus
09/14/2025, 6:28 PM/tmp as Thomas shows first.Thomas Danhorn
09/15/2025, 4:44 PMucl_myriad profile already sets runOptions. I believe (but am not 100% sure) that if you also set it to something (e.g. to bind /tmp to the scratch), you would override that original setting, which may or may not be fine (e.g., I don't see the benefit of -B ${HOME},${PWD} for nf-core pipelines, and --no-mount /scratch might even be contrary to what you are trying to do, but maybe --writable-tmpfs is required on that cluster for some reason). If it is not fine, you'd have to incorporate the relevant things into your own runOptions, ideally after discussing this with the sysadmins.ramya ranaganathan
09/16/2025, 9:39 AMThomas Danhorn
09/16/2025, 2:08 PM.bashrc should be the same, no matter what node you are on -- you only have a single $HOME where that resides, and it should be used whenever you use a shell anywhere. (But test in the scenario you are using, that it is actually used. There are complex rules, depending on if the shell is interactive, or not, a login shell, or not, etc,; normally it is set up that .bashrc is used pretty much always, but it does not hurt to check).
And yes, if you add what I said above to a config file and use it with -c, the /tmp in any Singularity container should be redirected to scratch, so you don't have to do anything else -- just let the processes write to /tmp. (The Myriad profile does not do anything with /tmp.)pontus
09/16/2025, 2:56 PMucl_mryiad profile does, you can actually mix runOptions with similar effects by making sure singularity/apptainer sees the right environment (which can be done with process.beforeScript, so e.g. beforeScript = 'export SINGULARITY_BIND=/somewhere:/tmp' in a relevant process definition could be helpful.ramya ranaganathan
09/17/2025, 11:27 AM