summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAchilleas Pipinellis <axilleas@axilleas.me>2016-06-04 12:47:15 +0000
committerAchilleas Pipinellis <axilleas@axilleas.me>2016-06-04 12:47:15 +0000
commit10758a48c508970d301d8a4e48e19c6c19765a94 (patch)
treec9d138e1ec25e82e913ab9c5f6bd788105030902
parentef85b8c32977391527919ea19e31b3b4648e07fb (diff)
parent2e8f039ae91767b912da2511d7697d7993293534 (diff)
downloadgitlab-ce-10758a48c508970d301d8a4e48e19c6c19765a94.tar.gz
Merge branch 'documentation-for-build-trace' into 'master'
Document the API endpoint for gathering a build log ## What does this MR do? Adds documentation for gathering a trace build log via the API. Documenting the following: https://gitlab.com/gitlab-org/gitlab-ce/blob/de20bd5b31715f096db3fb0155c82b0eea992b6c/lib/api/builds.rb#L98-110 ## Are there points in the code the reviewer needs to double check? Please verify that a curl request using the same format as documented works ## Why was this MR needed? No documentation currently exists ## What are the relevant issue numbers? #18015 ## Screenshots (if relevant) See merge request !4467
-rw-r--r--doc/api/builds.md24
1 files changed, 24 insertions, 0 deletions
diff --git a/doc/api/builds.md b/doc/api/builds.md
index 4c0a47d1ea0..5669bd0cdda 100644
--- a/doc/api/builds.md
+++ b/doc/api/builds.md
@@ -278,6 +278,30 @@ Response:
[ce-2893]: https://gitlab.com/gitlab-org/gitlab-ce/merge_requests/2893
+## Get a trace file
+
+Get a trace of a specific build of a project
+
+```
+GET /projects/:id/builds/:build_id/trace
+```
+
+| Attribute | Type | Required | Description |
+|------------|---------|----------|---------------------|
+| id | integer | yes | The ID of a project |
+| build_id | integer | yes | The ID of a build |
+
+```
+curl -H "PRIVATE-TOKEN: 9koXpg98eAheJpvBs5tK" "https://gitlab.example.com/api/v3/projects/1/builds/8/trace"
+```
+
+Response:
+
+| Status | Description |
+|-----------|-----------------------------------|
+| 200 | Serves the trace file |
+| 404 | Build not found or no trace file |
+
## Cancel a build
Cancel a single build of a project