summaryrefslogtreecommitdiff
path: root/doc/ci/yaml/README.md
diff options
context:
space:
mode:
authorAchilleas Pipinellis <axilleas@axilleas.me>2016-02-24 16:26:34 +0200
committerJames Edwards-Jones <jedwardsjones@gitlab.com>2017-01-31 22:55:31 +0000
commitc9b63ee44ccedbbd1fd8b1e7da57442a25dd2e2c (patch)
tree90d154c76e7c8eeeb08499c3126e00fb051a67ec /doc/ci/yaml/README.md
parent8f7eb4e3d04edc415af7a1dc58e96de366823c19 (diff)
downloadgitlab-ce-c9b63ee44ccedbbd1fd8b1e7da57442a25dd2e2c.tar.gz
Add pages job in yaml document
Diffstat (limited to 'doc/ci/yaml/README.md')
-rw-r--r--doc/ci/yaml/README.md29
1 files changed, 29 insertions, 0 deletions
diff --git a/doc/ci/yaml/README.md b/doc/ci/yaml/README.md
index f11257be5c3..ca293d54cb6 100644
--- a/doc/ci/yaml/README.md
+++ b/doc/ci/yaml/README.md
@@ -1281,6 +1281,35 @@ with an API call.
[Read more in the triggers documentation.](../triggers/README.md)
+### pages
+
+`pages` is a special job that is used to upload static content to GitLab that
+can be used to serve your website. It has a special syntax, so the two
+requirements below must be met:
+
+1. Any static content must be placed under a `public/` directory
+1. `artifacts` with a path to the `public/` directory must be defined
+
+The example below simply moves all files from the root of the project to the
+`public/` directory. The `.public` workaround is so `cp` doesn't also copy
+`public/` to itself in an infinite loop:
+
+```
+pages:
+ stage: deploy
+ script:
+ - mkdir .public
+ - cp -r * .public
+ - mv .public public
+ artifacts:
+ paths:
+ - public
+ only:
+ - master
+```
+
+Read more on [GitLab Pages user documentation](../../pages/README.md).
+
## Validate the .gitlab-ci.yml
Each instance of GitLab CI has an embedded debug tool called Lint.