Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boxiang Sun
gitlab-ce
Commits
d9f871f1
Commit
d9f871f1
authored
May 28, 2019
by
Grzegorz Bizon
Committed by
Douglas Barbosa Alexandre
May 28, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Docs for a downstream pipeline variables expansion
parent
1215a3f1
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
28 additions
and
0 deletions
+28
-0
doc/ci/multi_project_pipelines.md
doc/ci/multi_project_pipelines.md
+28
-0
No files found.
doc/ci/multi_project_pipelines.md
View file @
d9f871f1
...
...
@@ -134,6 +134,34 @@ staging:
The
`ENVIRONMENT`
variable will be passed to every job defined in a downstream
pipeline. It will be available as an environment variable when GitLab Runner picks a job.
In the following configuration, the
`MY_VARIABLE`
variable will be passed
downstream, because jobs inherit variables declared in top-level
`variables`
:
```
yaml
variables
:
MY_VARIABLE
:
my-value
my-pipeline
:
variables
:
ENVIRONMENT
:
something
trigger
:
my/project
```
You might want to pass some information about the upstream pipeline using, for
example, predefined variables. In order to do that, you can use interpolation
to pass any variable. For example:
```
yaml
my-pipeline
:
variables
:
UPSTREAM_BRANCH
:
$CI_COMMIT_REF_NAME
trigger
:
my/project
```
In this scenario, the
`UPSTREAM_BRANCH`
variable with a value related to the
upstream pipeline will be passed to a
`downstream`
job, and will be available
within the context of all downstream builds.
### Limitations
Because bridge jobs are a little different to regular jobs, it is not
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment