summaryrefslogtreecommitdiff
path: root/doc/ci/yaml/README.md
diff options
context:
space:
mode:
authorMart Sõmermaa <mart.somermaa@gmail.com>2018-06-18 20:27:11 +0000
committerRémy Coutable <remy@rymai.me>2018-08-29 17:35:38 +0200
commit4bcd8db335f567ac31754e28e26f1d7ddf3a7b99 (patch)
tree41bb22b74d43656808a255571a8271d18a29dc90 /doc/ci/yaml/README.md
parenteb034704768eeaa7f4605aaa8902b969adef5ec9 (diff)
downloadgitlab-ce-4bcd8db335f567ac31754e28e26f1d7ddf3a7b99.tar.gz
Add information how to run multi-platform builds with tags to doc/ci/yaml/README.md
Originally submitted at https://gitlab.com/gitlab-org/gitlab-ee/merge_requests/6176. Signed-off-by: Rémy Coutable <remy@rymai.me>
Diffstat (limited to 'doc/ci/yaml/README.md')
-rw-r--r--doc/ci/yaml/README.md22
1 files changed, 22 insertions, 0 deletions
diff --git a/doc/ci/yaml/README.md b/doc/ci/yaml/README.md
index abba748db8b..e93060fec85 100644
--- a/doc/ci/yaml/README.md
+++ b/doc/ci/yaml/README.md
@@ -390,6 +390,28 @@ job:
The specification above, will make sure that `job` is built by a Runner that
has both `ruby` AND `postgres` tags defined.
+Tags are also a great way to run different jobs on different platforms, for
+example, given an OS X Runner with tag `osx` and Windows Runner with tag
+`windows`, the following jobs run on respective platforms:
+
+```yaml
+windows job:
+ stage:
+ - build
+ tags:
+ - windows
+ script:
+ - echo Hello, %USERNAME%!
+
+osx job:
+ stage:
+ - build
+ tags:
+ - osx
+ script:
+ - echo "Hello, $USER!"
+```
+
## `allow_failure`
`allow_failure` is used when you want to allow a job to fail without impacting