简体   繁体   English

使用 Jenkins 同时执行 2 个 python 脚本

[英]Execute 2 python scripts simultaneously using Jenkins

I have 2 python scripts that I want to execute at the same time using Jenkins, however every method I have tried executes the first one and waits for it to finish in order to start the next.我有 2 个想要使用 Jenkins 同时执行的 python 脚本,但是我尝试过的每种方法都会执行第一个并等待它完成以开始下一个。 Does anyone have a solution for this?有没有人对此有解决方案? Another option is to maybe make 2 builds in jenkins and have the 2nd one start building a minute or so after the first, but I am not sure how to do that either...另一种选择是可能在 jenkins 中进行 2 个构建,并在第一个之后一分钟左右开始构建第二个,但我也不知道如何做到这一点......

You can use Parallel Stage by using pipelines.您可以通过使用管道来使用 Parallel Stage。 This way you can run your scripts in the same time.这样您就可以同时运行脚本。

You can check this for more details.您可以查看此了解更多详细信息。 https://jenkins.io/doc/book/pipeline/syntax/#parallel https://jenkins.io/doc/book/pipeline/syntax/#parallel

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM