From c0f886035ce681a75587cf5b80661978ab262094 Mon Sep 17 00:00:00 2001 From: Koch <8436725+reikoch@users.noreply.github.com> Date: Mon, 8 Nov 2021 12:18:58 +0100 Subject: [PATCH] allow LSF commands via ssh --- DESCRIPTION | 2 +- R/clusterFunctionsLSF.R | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 300cacbd..4bd70daf 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,6 +1,6 @@ Package: batchtools Title: Tools for Computation on Batch Systems -Version: 0.9.16 +Version: 0.9.15.9000 Authors@R: c( person("Michel", "Lang", NULL, "michellang@gmail.com", role = c("cre", "aut"), comment = c(ORCID = "0000-0001-9754-0393")), diff --git a/R/clusterFunctionsLSF.R b/R/clusterFunctionsLSF.R index c151c697..b1e0596d 100644 --- a/R/clusterFunctionsLSF.R +++ b/R/clusterFunctionsLSF.R @@ -23,7 +23,7 @@ #' @return [\code{\link{ClusterFunctions}}]. #' @family ClusterFunctions #' @export -makeClusterFunctionsLSF = function(template = "lsf", scheduler.latency = 1, fs.latency = 65) { # nocov start +makeClusterFunctionsLSF = function(template = "lsf", nodename = "localhost", scheduler.latency = 1, fs.latency = 65) { # nocov start template = findTemplateFile(template) if (testScalarNA(template)) stopf("Argument 'template' (=\"%s\") must point to a readable template file or contain the template itself as string (containing at least one newline)", template) @@ -38,7 +38,7 @@ makeClusterFunctionsLSF = function(template = "lsf", scheduler.latency = 1, fs.l assertRegistry(reg, writeable = TRUE) assertClass(jc, "JobCollection") outfile = cfBrewTemplate(reg, template, jc) - res = runOSCommand("bsub", stdin = outfile) + res = runOSCommand("bsub", stdin = outfile, nodename = nodename) if (res$exit.code > 0L) { cfHandleUnknownSubmitError("bsub", res$exit.code, res$output) @@ -50,7 +50,7 @@ makeClusterFunctionsLSF = function(template = "lsf", scheduler.latency = 1, fs.l listJobs = function(reg, args) { assertRegistry(reg, writeable = FALSE) - res = runOSCommand("bjobs", args) + res = runOSCommand("bjobs", args, nodename = nodename) if (res$exit.code > 0L) { if (res$exit.code == 255L || any(stri_detect_regex(res$output, "No (unfinished|pending|running) job found"))) return(character(0L))