【gitlab 多工程的pipeline】
作者:互联网
gitlab 多工程的pipeline
文献:
https://www.kancloud.cn/apachecn/gitlab-doc-zh/1948835
https://docs.gitlab.com/ee/ci/pipelines/multi_project_pipelines.html
遗留问题点
- 是否可以触发mr
- 是否可以等待子流水线运行结束,也就是控制串型或者并行 【好像可以使用 strategy: depend 】
两种方法
- 在.gitlab-ci.yml中定义
- 使用api
.gitlab-ci.yml
rspec:
stage: test
script: bundle exec rspec
staging:
variables:
ENVIRONMENT: staging
stage: deploy
trigger: my/deployment
rspec:
stage: test
script: bundle exec rspec
staging:
stage: deploy
trigger:
project: downstream/project
branch: $CI_COMMIT_REF_NAME
variables:
MY_GLOBAL_VAR: value
trigger-downstream:
inherit:
variables: false
variables:
MY_LOCAL_VAR: value
trigger: my/project
trigger_job:
trigger:
project: my/project
strategy: depend
api
标签:pipeline,工程,variables,gitlab,rspec,project,trigger,stage 来源: https://blog.csdn.net/xiaolixi199311/article/details/122269213