summaryrefslogtreecommitdiff
path: root/doc/development/cicd/templates.md
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2021-06-28 21:10:13 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2021-06-28 21:10:13 +0000
commit8f016fe5fb42704dd949e77859888fcd898fd985 (patch)
tree32c3c311c5fb330769601b2cf684aebe6f102196 /doc/development/cicd/templates.md
parente4632f4c63eae7ec36243d11b23d69b4fd880830 (diff)
downloadgitlab-ce-8f016fe5fb42704dd949e77859888fcd898fd985.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'doc/development/cicd/templates.md')
-rw-r--r--doc/development/cicd/templates.md14
1 files changed, 7 insertions, 7 deletions
diff --git a/doc/development/cicd/templates.md b/doc/development/cicd/templates.md
index eddaabe41d8..204287d7b59 100644
--- a/doc/development/cicd/templates.md
+++ b/doc/development/cicd/templates.md
@@ -16,7 +16,7 @@ Before submitting a merge request with a new or updated CI/CD template, you must
- Place the template in the correct [directory](#template-directories).
- Follow the [CI/CD template authoring guidelines](#template-authoring-guidelines).
- Name the template following the `*.gitlab-ci.yml` format.
-- Use valid [`.gitlab-ci.yml` syntax](../../ci/yaml/README.md). Verify it's valid
+- Use valid [`.gitlab-ci.yml` syntax](../../ci/yaml/index.md). Verify it's valid
with the [CI/CD lint tool](../../ci/lint.md).
- Include [a changelog](../changelog.md) if the merge request introduces a user-facing change.
- Follow the [template review process](#contribute-cicd-template-merge-requests).
@@ -59,8 +59,8 @@ don't have any other `.gitlab-ci.yml` files.
When authoring pipeline templates:
-- Place any [global keywords](../../ci/yaml/README.md#global-keywords) like `image`
- or `before_script` in a [`default`](../../ci/yaml/README.md#custom-default-keyword-values)
+- Place any [global keywords](../../ci/yaml/index.md#global-keywords) like `image`
+ or `before_script` in a [`default`](../../ci/yaml/index.md#custom-default-keyword-values)
section at the top of the template.
- Note clearly in the [code comments](#explain-the-template-with-comments) if the
template is designed to be used with the `includes` keyword in an existing
@@ -68,7 +68,7 @@ When authoring pipeline templates:
A **job template** provides specific jobs that can be added to an existing CI/CD
workflow to accomplish specific tasks. It usually should be used by adding it to
-an existing `.gitlab-ci.yml` file by using the [`includes`](../../ci/yaml/README.md#global-keywords)
+an existing `.gitlab-ci.yml` file by using the [`includes`](../../ci/yaml/index.md#global-keywords)
keyword. You can also copy and paste the contents into an existing `.gitlab-ci.yml` file.
Configure job templates so that users can add them to their current pipeline with very
@@ -77,7 +77,7 @@ other pipeline configuration.
When authoring job templates:
-- Do not use [global](../../ci/yaml/README.md#global-keywords) or [`default`](../../ci/yaml/README.md#custom-default-keyword-values)
+- Do not use [global](../../ci/yaml/index.md#global-keywords) or [`default`](../../ci/yaml/index.md#custom-default-keyword-values)
keywords. When a root `.gitlab-ci.yml` includes a template, global or default keywords
might be overridden and cause unexpected behavior. If a job template requires a
specific stage, explain in the code comments that users must manually add the stage
@@ -127,8 +127,8 @@ job2:
#### Use `rules` instead of `only` or `except`
-Avoid using [`only` or `except`](../../ci/yaml/README.md#only--except) if possible.
-Only and except is not being developed any more, and [`rules`](../../ci/yaml/README.md#rules)
+Avoid using [`only` or `except`](../../ci/yaml/index.md#only--except) if possible.
+Only and except is not being developed any more, and [`rules`](../../ci/yaml/index.md#rules)
is now the preferred syntax:
```yaml