1
0
Fork 0
mirror of https://github.com/MillironX/nf-configs.git synced 2024-12-03 12:19:56 +00:00

Execute sinfo with bash shell

This commit is contained in:
Mahesh Binzer-Panchal 2022-03-25 13:58:37 +00:00
parent 7d72e8d94b
commit 3a7f7f431e

View file

@ -23,7 +23,7 @@ singularity {
def hostname = "r1"
try {
hostname = "sinfo --local -N -h | grep -m 1 -F -v CLUSTER: | cut -f1 -d' ' ".execute().text.trim()
hostname = ['/bin/bash', '-c', 'sinfo --local -N -h | grep -m 1 -F -v CLUSTER: | cut -f1 -d" "'].execute().text.trim()
} catch (java.io.IOException e) {
System.err.println("WARNING: Could not run sinfo to determine current cluster, defaulting to rackham")
}