summaryrefslogtreecommitdiff
path: root/doc/ci/multi_project_pipelines.md
diff options
context:
space:
mode:
Diffstat (limited to 'doc/ci/multi_project_pipelines.md')
-rw-r--r--doc/ci/multi_project_pipelines.md27
1 files changed, 25 insertions, 2 deletions
diff --git a/doc/ci/multi_project_pipelines.md b/doc/ci/multi_project_pipelines.md
index 40d495a69f1..3df2db8539e 100644
--- a/doc/ci/multi_project_pipelines.md
+++ b/doc/ci/multi_project_pipelines.md
@@ -62,6 +62,14 @@ together, allowing you to visualize their relationships on pipeline graphs.
These relationships are displayed in the pipeline graph by showing inbound and
outbound connections for upstream and downstream pipeline dependencies.
+When using:
+
+- Variables or [`rules`](yaml/README.md#rulesif) to control job behavior, the value of
+ the [`$CI_PIPELINE_SOURCE` predefined variable](variables/predefined_variables.md) is
+ `pipeline` for multi-project pipeline triggered through the API with `CI_JOB_TOKEN`.
+- [`only/except`](yaml/README.md#onlyexcept-basic) to control job behavior, use the
+ `pipelines` keyword.
+
## Creating multi-project pipelines from `.gitlab-ci.yml`
> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/8997) in [GitLab Premium](https://about.gitlab.com/pricing/) 11.8.
@@ -100,6 +108,15 @@ downstream project (`my/deployment` in this case). If a downstream project can
not be found, or a user does not have access rights to create pipeline there,
the `staging` job is going to be marked as _failed_.
+When using:
+
+- Variables or [`rules`](yaml/README.md#rulesif) to control job behavior, the value of
+ the [`$CI_PIPELINE_SOURCE` predefined variable](variables/predefined_variables.md) is
+ `pipeline` for multi-project pipelines triggered with a bridge job (using the
+ [`trigger:`](yaml/README.md#trigger) keyword).
+- [`only/except`](yaml/README.md#onlyexcept-basic) to control job behavior, use the
+ `pipelines` keyword.
+
CAUTION: **Caution:**
In the example, `staging` will be marked as succeeded as soon as a downstream pipeline
gets created. If you want to display the downstream pipeline's status instead, see
@@ -138,6 +155,12 @@ Use:
GitLab will use a commit that is currently on the HEAD of the branch when
creating a downstream pipeline.
+NOTE: **Note:**
+Pipelines triggered on a protected branch in a downstream project use the [permissions](../user/permissions.md)
+of the user that ran the trigger job in the upstream project. If the user does not
+have permission to run CI/CD pipelines against the protected branch, the pipeline fails. See
+[pipeline security for protected branches](pipelines/index.md#pipeline-security-on-protected-branches).
+
### Passing variables to a downstream pipeline
Sometimes you might want to pass variables to a downstream pipeline.
@@ -254,5 +277,5 @@ tag in a different project:
Any pipelines that complete successfully for new tags in the subscribed project
will now trigger a pipeline on the current project's default branch. The maximum
-number of upstream pipeline subscriptions is 2, for both the upstream and
-downstream projects.
+number of upstream pipeline subscriptions is 2 by default, for both the upstream and
+downstream projects. This [application limit](../administration/instance_limits.md#number-of-cicd-subscriptions-to-a-project) can be changed on self-managed instances by a GitLab administrator.