【问题标题】:Select nodes to execute Nextflow workflow with Kubernete选择节点以使用 Kubernetes 执行 Nextflow 工作流
【发布时间】:2021-10-14 19:43:57
【问题描述】:

我可以访问具有大量节点的集群。我正在使用以下命令运行我的 Nextflow 工作流程:

./nextflow kuberun user/repo -c nextflow.config -profile kubernetes -v my_pvc:/mounted_path -with-report _report.html -with-trace _trace

我想在一组特定的节点上运行我的 nextflow 工作流程。我已经标记了我感兴趣的节点:

kubectl label nodes node1 disktype=my_experiment
kubectl label nodes node2 disktype=my_experiment
kubectl label nodes node3 disktype=my_experiment

我从 Nextflow 和 Kubernetes 文档中无法理解如何安排我的工作流程,而这些流程在我感兴趣的节点之间进行拆分。

我只了解如何使用 kubernete:https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/

但不是nextflow kuberun 命令的用法。

非常感谢任何帮助,谢谢!

【问题讨论】:

    标签: kubernetes kubernetes-pod nextflow


    【解决方案1】:

    使用一个或多个 process selectorspod directive 使用 pod 标签选择节点。例如,可以将以下内容添加到您的“kubernetes”配置文件中:

    process {
    
        withName: my_process {
            pod {
                nodeSelector = 'disktype=my_experiment'
             }
         }
        ...
    }
    

    【讨论】:

    • 感谢您的回复。它对我帮助很大!对我有用的确切语法来自这里:github.com/nextflow-io/nextflow/issues/955 withName:FASTP { pod { nodeSelector = 'disktype=my_experiment' } } 也许你可以用它来编辑你的答案?
    • @Nine 完美,很高兴它有帮助!
    猜你喜欢
    • 2019-04-28
    • 2021-01-12
    • 2010-09-22
    • 2021-11-14
    • 1970-01-01
    • 2011-06-18
    • 2021-09-18
    • 1970-01-01
    • 2021-06-22
    相关资源
    最近更新 更多