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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
55ef6d72
Commit
55ef6d72
authored
Apr 14, 2021
by
Evan Read
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Promote dependencies section
parent
9c35c043
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
70 additions
and
70 deletions
+70
-70
doc/ci/yaml/README.md
doc/ci/yaml/README.md
+70
-70
No files found.
doc/ci/yaml/README.md
View file @
55ef6d72
...
...
@@ -3169,6 +3169,76 @@ artifacts are restored after [caches](#cache).
[
Read more about artifacts
](
../pipelines/job_artifacts.md
)
.
#### `dependencies`
By default, all
`artifacts`
from previous stages
are passed to each job. However, you can use the
`dependencies`
keyword to
define a limited list of jobs to fetch artifacts from. You can also set a job to download no artifacts at all.
To use this feature, define
`dependencies`
in context of the job and pass
a list of all previous jobs the artifacts should be downloaded from.
You can define jobs from stages that were executed before the current one.
An error occurs if you define jobs from the current or an upcoming stage.
To prevent a job from downloading artifacts, define an empty array.
When you use
`dependencies`
, the status of the previous job is not considered.
If a job fails or it's a manual job that isn't triggered, no error occurs.
The following example defines two jobs with artifacts:
`build:osx`
and
`build:linux`
. When the
`test:osx`
is executed, the artifacts from
`build:osx`
are downloaded and extracted in the context of the build. The same happens
for
`test:linux`
and artifacts from
`build:linux`
.
The job
`deploy`
downloads artifacts from all previous jobs because of
the
[
stage
](
#stages
)
precedence:
```
yaml
build:osx:
stage
:
build
script
:
make build:osx
artifacts
:
paths
:
-
binaries/
build:linux:
stage
:
build
script
:
make build:linux
artifacts
:
paths
:
-
binaries/
test:osx:
stage
:
test
script
:
make test:osx
dependencies
:
-
build:osx
test:linux:
stage
:
test
script
:
make test:linux
dependencies
:
-
build:linux
deploy
:
stage
:
deploy
script
:
make deploy
```
##### When a dependent job fails
> Introduced in GitLab 10.3.
If the artifacts of the job that is set as a dependency are
[
expired
](
#artifactsexpire_in
)
or
[
erased
](
../pipelines/job_artifacts.md#erase-job-artifacts
)
, then
the dependent job fails.
You can ask your administrator to
[
flip this switch
](
../../administration/job_artifacts.md#validation-for-dependencies
)
and bring back the old behavior.
#### `artifacts:exclude`
> - [Introduced](https://gitlab.com/gitlab-org/gitlab/-/issues/15122) in GitLab 13.1
...
...
@@ -3717,76 +3787,6 @@ plan report uploads to GitLab as an artifact and displays
in merge requests. For more information, see
[
Output `terraform plan` information into a merge request
](
../../user/infrastructure/mr_integration.md
)
.
##### `dependencies`
By default, all
`artifacts`
from previous stages
are passed to each job. However, you can use the
`dependencies`
keyword to
define a limited list of jobs to fetch artifacts from. You can also set a job to download no artifacts at all.
To use this feature, define
`dependencies`
in context of the job and pass
a list of all previous jobs the artifacts should be downloaded from.
You can define jobs from stages that were executed before the current one.
An error occurs if you define jobs from the current or an upcoming stage.
To prevent a job from downloading artifacts, define an empty array.
When you use
`dependencies`
, the status of the previous job is not considered.
If a job fails or it's a manual job that isn't triggered, no error occurs.
The following example defines two jobs with artifacts:
`build:osx`
and
`build:linux`
. When the
`test:osx`
is executed, the artifacts from
`build:osx`
are downloaded and extracted in the context of the build. The same happens
for
`test:linux`
and artifacts from
`build:linux`
.
The job
`deploy`
downloads artifacts from all previous jobs because of
the
[
stage
](
#stages
)
precedence:
```
yaml
build:osx:
stage
:
build
script
:
make build:osx
artifacts
:
paths
:
-
binaries/
build:linux:
stage
:
build
script
:
make build:linux
artifacts
:
paths
:
-
binaries/
test:osx:
stage
:
test
script
:
make test:osx
dependencies
:
-
build:osx
test:linux:
stage
:
test
script
:
make test:linux
dependencies
:
-
build:linux
deploy
:
stage
:
deploy
script
:
make deploy
```
###### When a dependent job fails
> Introduced in GitLab 10.3.
If the artifacts of the job that is set as a dependency are
[
expired
](
#artifactsexpire_in
)
or
[
erased
](
../pipelines/job_artifacts.md#erase-job-artifacts
)
, then
the dependent job fails.
You can ask your administrator to
[
flip this switch
](
../../administration/job_artifacts.md#validation-for-dependencies
)
and bring back the old behavior.
#### `artifacts:untracked`
Use
`artifacts:untracked`
to add all Git untracked files as artifacts (along
...
...
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