OSDN Git Service

CI: Capture test logs as GitLab artifacts
authorDaniel Stone <daniels@collabora.com>
Thu, 6 Sep 2018 10:01:17 +0000 (11:01 +0100)
committerEmil Velikov <emil.l.velikov@gmail.com>
Thu, 4 Oct 2018 13:37:07 +0000 (14:37 +0100)
GitLab CI already captures all the stdout/stderr output from the build
process as the log. However, some other important information is hidden
in other log files.

Taken from Wayland, capture logs from the configuration process as well
as from every check.

Signed-off-by: Daniel Stone <daniels@collabora.com>
Cc: Rodrigo Vivi <rodrigo.vivi@gmail.com>
Cc: Lucas De Marchi <lucas.de.marchi@gmail.com>
Cc: Eric Engeström <eric.engestrom@intel.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Acked-by: Eric Engestrom <eric.engestrom@intel.com>
[Emil: use wildcard to match the artefacts]
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
.gitlab-ci.yml

index 1dc434a..fe9b47d 100644 (file)
@@ -1,3 +1,15 @@
+.artifacts-meson: &artifacts-meson
+  when: always
+  paths:
+   - _build/meson-logs
+
+.artifacts-autotools: &artifacts-autotools
+  when: always
+  paths:
+    - _build/*.log
+    - _build/*/*.log
+    - _build/*/*/*.log
+
 .meson-build: &meson-build
   - meson _build
       -D amdgpu=true
@@ -58,6 +70,7 @@ latest-meson:
 latest-autotools:
   stage: build
   image: base/archlinux:latest
+  artifacts: *artifacts-autotools
   before_script:
     - pacman -Syu --noconfirm --needed
         base-devel
@@ -73,6 +86,7 @@ latest-autotools:
 oldest-meson:
   stage: build
   image: debian:stable
+  artifacts: *artifacts-meson
   before_script:
     - printf > /etc/dpkg/dpkg.cfg.d/99-exclude-cruft "%s\n"
         'path-exclude=/usr/share/doc/*'
@@ -109,6 +123,7 @@ oldest-meson:
 oldest-autotools:
   stage: build
   image: debian:stable
+  artifacts: *artifacts-autotools
   before_script:
     - printf > /etc/dpkg/dpkg.cfg.d/99-exclude-cruft "%s\n"
         'path-exclude=/usr/share/doc/*'