Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/doc/ci/yaml
diff options
context:
space:
mode:
authorKamil Trzciński <ayufan@ayufan.eu>2016-02-18 15:24:54 +0300
committerKamil Trzciński <ayufan@ayufan.eu>2016-02-18 15:24:54 +0300
commitb352dbaba660e8d6b8a686a97d37ff3c4ee775e2 (patch)
treed47c9c99664b14b608cd2c2fb4cc998fb9bef0f0 /doc/ci/yaml
parent8b918267c7477f7e1a36b4f3cc12c9e244204cb9 (diff)
parent150bee38b4e1754686821a6a2761d6f0bb6e69f6 (diff)
Merge branch 'patch-1' into 'master'
Add example of creating build artifacts only for release tags. See merge request !2649
Diffstat (limited to 'doc/ci/yaml')
-rw-r--r--doc/ci/yaml/README.md26
1 files changed, 24 insertions, 2 deletions
diff --git a/doc/ci/yaml/README.md b/doc/ci/yaml/README.md
index 194c8171bb9..461a545c474 100644
--- a/doc/ci/yaml/README.md
+++ b/doc/ci/yaml/README.md
@@ -428,8 +428,30 @@ artifacts:
- binaries/
```
-The artifacts will be send after a successful build success to GitLab, and will
-be accessible in the GitLab UI to download.
+You may want to create artifacts only for tagged releases to avoid filling the
+build server storage with temporary build artifacts.
+
+Create artifacts only for tags (`default-job` will not create artifacts):
+
+```yaml
+default-job:
+ script:
+ - mvn test -U
+ except:
+ - tags
+
+release-job:
+ script:
+ - mvn package -U
+ artifacts:
+ paths:
+ - target/*.war
+ only:
+ - tags
+```
+
+The artifacts will be sent to GitLab after a successful build and will
+be available for download in the GitLab UI.
### cache