英文:
Azure pipeline doesn't triggers after completion of previous pipeline
问题
In Azure DevOps,在Azure DevOps中,我有2个流水线,我们称之为流水线A和流水线B。 Pipeline A is scheduled to run daily. Pipeline A被安排每天运行。Upon successful completion of Pipeline A, I want to trigger Pipeline B.成功完成Pipeline A后,我想触发Pipeline B。
I've added the snippet that should trigger Pipeline B upon successful completion of Pipeline A. But it doesn't work. How can I fix that?我已经添加了应该在Pipeline A成功完成后触发Pipeline B的代码片段。但它不起作用。我该如何修复这个问题?
trigger: none
resources:
pipelines:
- pipeline: AliasA
source: Pipeline A # Name of the pipeline that triggers this pipeline
trigger:
branches:
- branch_prod # Branches that will trigger this pipeline
trigger: none
resources:
pipelines:
- pipeline: AliasA
source: Pipeline A # 触发此流水线的流水线名称
trigger:
branches:
- branch_prod # 会触发此流水线的分支
以上是您提供的代码部分的翻译。
英文:
In Azure DevOps I have 2 pipelines let's say Pipeline A and Pipeline B. Pipeline A is scheduled to run daily. Upon successful completion of Pipeline A I want to trigger Pipeline B.
I've added the snippet that should trigger Pipeline B upon successful completion of Pipeline A. But it doesn't work. How can I fix that?
trigger: none
resources:
pipelines:
- pipeline: AliasA
source: Pipeline A # Name of the pipeline that triggers this pipeline
trigger:
branches:
- branch_prod # Branches that will trigger this pipeline
答案1
得分: 1
试一下:
资源:
管道:
- 管道: 别名A # 管道资源的名称。
源: 管道A # 此管道资源引用的管道的名称。
项目: 项目 # 仅在源管道位于另一个项目中时需要
触发器: true # 当yyy的任何运行完成时运行xx管道
英文:
Try this:
resources:
pipelines:
- pipeline: AliasA # Name of the pipeline resource.
source: PipelineA # The name of the pipeline referenced by this pipeline resource.
project: Project # Required only if the source pipeline is in another project
trigger: true # Run xx pipeline when any run of yyy completes
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论