If a job has a cluster field and its' value is not "cs-localhost" or empty, will regard it as a cluster job.
When running a cluster job with cluster value "localhost", its' actions depend on field "node_roles", default is "server client".
Signed-off-by: Ren Wen 15991987063@163.com --- src/scheduler/submit_job.cr | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/src/scheduler/submit_job.cr b/src/scheduler/submit_job.cr index 8838e40..2836275 100644 --- a/src/scheduler/submit_job.cr +++ b/src/scheduler/submit_job.cr @@ -9,10 +9,8 @@ class Sched job = Job.new(job_content, job_content["id"]?) job["commit_date"] = get_commit_date(job)
- # it is not a cluster job if cluster field is empty or - # field's prefix is 'cs-localhost' cluster_file = job["cluster"] - if cluster_file.empty? || cluster_file.starts_with?("cs-localhost") + if cluster_file.empty? || cluster_file == "cs-localhost" return submit_single_job(job) else cluster_config = get_cluster_config(cluster_file,