summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorAchilleas Pipinellis <axilleas@axilleas.me>2016-11-17 08:54:51 +0100
committerAchilleas Pipinellis <axilleas@axilleas.me>2016-11-17 08:54:51 +0100
commitff97de61df3ebbeea31e5fef833e8a477c13ab3c (patch)
tree1f28fec0ab85940c0df72ee41a9d95e97b1e8387 /doc
parent3a6e38db5316a73809c3303de2aa8a0ece866fcc (diff)
downloadgitlab-ce-ff97de61df3ebbeea31e5fef833e8a477c13ab3c.tar.gz
Move name rules under environment:name in yaml readme
Diffstat (limited to 'doc')
-rw-r--r--doc/ci/yaml/README.md33
1 files changed, 17 insertions, 16 deletions
diff --git a/doc/ci/yaml/README.md b/doc/ci/yaml/README.md
index 5c0e1c44e3f..bc9c0897f5a 100644
--- a/doc/ci/yaml/README.md
+++ b/doc/ci/yaml/README.md
@@ -552,28 +552,14 @@ An example usage of manual actions is deployment to production.
If `environment` is specified and no environment under that name exists, a new
one will be created automatically.
-The `environment` name can contain:
-
-- letters
-- digits
-- spaces
-- `-`
-- `_`
-- `/`
-- `$`
-- `{`
-- `}`
-
-Common names are `qa`, `staging`, and `production`, but you can use whatever
-name works with your workflow.
-
In its simplest form, the `environment` keyword can be defined like:
```
deploy to production:
stage: deploy
script: git push production HEAD:master
- environment: production
+ environment:
+ name: production
```
In the above example, the `deploy to production` job will be marked as doing a
@@ -588,6 +574,21 @@ Before GitLab 8.11, the name of an environment could be defined as a string like
`environment: production`. The recommended way now is to define it under the
`name` keyword.
+The `environment` name can contain:
+
+- letters
+- digits
+- spaces
+- `-`
+- `_`
+- `/`
+- `$`
+- `{`
+- `}`
+
+Common names are `qa`, `staging`, and `production`, but you can use whatever
+name works with your workflow.
+
Instead of defining the name of the environment right after the `environment`
keyword, it is also possible to define it as a separate value. For that, use
the `name` keyword under `environment`: