gpt4 book ai didi

unix - Jenkins 中的流水线和项目有什么区别?

转载 作者:行者123 更新时间:2023-12-04 18:59:29 31 4
gpt4 key购买 nike

Jenkins 中的流水线和项目有什么区别?我可以从 Pipeline 调用一个项目吗?如果是,如何使用 linux 节点?

最佳答案

在 Jenkins 中,项目就是工作。作业可以包含管道,但也可以包含其他工作流。
Jenkins docs intro to pipeline

Jenkins Pipeline is a suite of plugins which supports implementing and integrating continuous delivery pipelines into Jenkins. Pipeline provides an extensible set of tools for modeling simple-to-complex delivery pipelines "as code" via the Pipeline DSL. 1


Jenkins Terminology

Job/Project: Jenkins seems to use these terms interchangeably. They all refer to runnable tasks that are controlled / monitored by Jenkins.


管道有一个 DSL(领域特定语言),它只能在 Jenkins 管道作业中工作。以下是如何在管道项目中的 Linux 节点上运行现有作业/项目的示例。
// specify your linux node by name
node('linux') {

// run the project job named your-other-job
stage('run project') {
build 'your-other-job'
}

}
要深入挖掘,请务必查看 Jenkins 内置的有用语法生成器。
enter image description here
these pipeline examples

关于unix - Jenkins 中的流水线和项目有什么区别?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41267370/

31 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com