From: Claudio Imbrenda <imbrenda@linux.ibm.com>
To: Thomas Huth <thuth@redhat.com>
Cc: kvm@vger.kernel.org, Paolo Bonzini <pbonzini@redhat.com>,
Andrew Jones <andrew.jones@linux.dev>,
Janosch Frank <frankja@linux.ibm.com>,
Nico Boehr <nrb@linux.ibm.com>
Subject: Re: [kvm-unit-tests PATCH] ci: Provide the logs as artifacts
Date: Mon, 3 Apr 2023 12:56:46 +0200 [thread overview]
Message-ID: <20230403125646.18fe06f4@p-imbrenda> (raw)
In-Reply-To: <20230403093255.45104-1-thuth@redhat.com>
On Mon, 3 Apr 2023 11:32:55 +0200
Thomas Huth <thuth@redhat.com> wrote:
> If something goes wrong, it's good to have a way to see where it failed,
> so let's provide the logs as artifacts.
>
> While we're at it, also dump /proc/cpuinfo in the Fedora KVM job
> as this might contain valuable information about the KVM environment.
>
> Signed-off-by: Thomas Huth <thuth@redhat.com>
Acked-by: Claudio Imbrenda <imbrenda@linux.ibm.com>
> ---
> .gitlab-ci.yml | 22 ++++++++++++++++++++++
> ci/cirrus-ci-fedora.yml | 6 ++++++
> ci/cirrus-ci-macos-i386.yml | 4 ++++
> ci/cirrus-ci-macos-x86-64.yml | 4 ++++
> 4 files changed, 36 insertions(+)
>
> diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
> index ad7949c9..59a3d3c8 100644
> --- a/.gitlab-ci.yml
> +++ b/.gitlab-ci.yml
> @@ -4,7 +4,20 @@ before_script:
> - dnf update -y
> - dnf install -y make python
>
> +.intree_template:
> + artifacts:
> + expire_in: 2 days
> + paths:
> + - logs
> +
> +.outoftree_template:
> + artifacts:
> + expire_in: 2 days
> + paths:
> + - build/logs
> +
> build-aarch64:
> + extends: .intree_template
> script:
> - dnf install -y qemu-system-aarch64 gcc-aarch64-linux-gnu
> - ./configure --arch=aarch64 --cross-prefix=aarch64-linux-gnu-
> @@ -35,6 +48,7 @@ build-aarch64:
> - if grep -q FAIL results.txt ; then exit 1 ; fi
>
> build-arm:
> + extends: .outoftree_template
> script:
> - dnf install -y qemu-system-arm gcc-arm-linux-gnu
> - mkdir build
> @@ -49,6 +63,7 @@ build-arm:
> - if grep -q FAIL results.txt ; then exit 1 ; fi
>
> build-ppc64be:
> + extends: .outoftree_template
> script:
> - dnf install -y qemu-system-ppc gcc-powerpc64-linux-gnu
> - mkdir build
> @@ -62,6 +77,7 @@ build-ppc64be:
> - if grep -q FAIL results.txt ; then exit 1 ; fi
>
> build-ppc64le:
> + extends: .intree_template
> script:
> - dnf install -y qemu-system-ppc gcc-powerpc64-linux-gnu
> - ./configure --arch=ppc64 --endian=little --cross-prefix=powerpc64-linux-gnu-
> @@ -73,6 +89,7 @@ build-ppc64le:
> - if grep -q FAIL results.txt ; then exit 1 ; fi
>
> build-s390x:
> + extends: .outoftree_template
> script:
> - dnf install -y qemu-system-s390x gcc-s390x-linux-gnu
> - mkdir build
> @@ -109,6 +126,7 @@ build-s390x:
> - if grep -q FAIL results.txt ; then exit 1 ; fi
>
> build-x86_64:
> + extends: .intree_template
> script:
> - dnf install -y qemu-system-x86 gcc
> - ./configure --arch=x86_64
> @@ -147,6 +165,7 @@ build-x86_64:
> - if grep -q FAIL results.txt ; then exit 1 ; fi
>
> build-i386:
> + extends: .outoftree_template
> script:
> - dnf install -y qemu-system-x86 gcc
> - mkdir build
> @@ -180,6 +199,7 @@ build-i386:
> - if grep -q FAIL results.txt ; then exit 1 ; fi
>
> build-clang:
> + extends: .intree_template
> script:
> - dnf install -y qemu-system-x86 clang
> - ./configure --arch=x86_64 --cc=clang
> @@ -218,6 +238,7 @@ build-clang:
> - grep -q PASS results.txt && ! grep -q FAIL results.txt
>
> build-centos7:
> + extends: .outoftree_template
> image: centos:7
> before_script:
> - yum update -y
> @@ -266,6 +287,7 @@ cirrus-ci-macos-x86-64:
> <<: *cirrus_build_job_definition
>
> s390x-kvm:
> + extends: .intree_template
> before_script: []
> tags:
> - s390x-z15-vm
> diff --git a/ci/cirrus-ci-fedora.yml b/ci/cirrus-ci-fedora.yml
> index d6070f70..918c9a36 100644
> --- a/ci/cirrus-ci-fedora.yml
> +++ b/ci/cirrus-ci-fedora.yml
> @@ -13,6 +13,8 @@ fedora_task:
> - git fetch origin "@CI_COMMIT_REF_NAME@"
> - git reset --hard "@CI_COMMIT_SHA@"
> script:
> + - uname -r
> + - sed -n "/processor.*:.0/,/^$/p" /proc/cpuinfo
> - mkdir build
> - cd build
> - ../configure
> @@ -70,3 +72,7 @@ fedora_task:
> xsave
> | tee results.txt
> - grep -q PASS results.txt && ! grep -q FAIL results.txt
> + on_failure:
> + log_artifacts:
> + path: build/logs/*.log
> + type: text/plain
> diff --git a/ci/cirrus-ci-macos-i386.yml b/ci/cirrus-ci-macos-i386.yml
> index ed580e61..45d1b716 100644
> --- a/ci/cirrus-ci-macos-i386.yml
> +++ b/ci/cirrus-ci-macos-i386.yml
> @@ -35,3 +35,7 @@ macos_i386_task:
> vmexit_tscdeadline_immed
> | tee results.txt
> - grep -q PASS results.txt && ! grep -q FAIL results.txt
> + on_failure:
> + log_artifacts:
> + path: build/logs/*.log
> + type: text/plain
> diff --git a/ci/cirrus-ci-macos-x86-64.yml b/ci/cirrus-ci-macos-x86-64.yml
> index 861caa16..8ee6fb7e 100644
> --- a/ci/cirrus-ci-macos-x86-64.yml
> +++ b/ci/cirrus-ci-macos-x86-64.yml
> @@ -39,3 +39,7 @@ macos_task:
> vmexit_tscdeadline_immed
> | tee results.txt
> - grep -q PASS results.txt && ! grep -q FAIL results.txt
> + on_failure:
> + log_artifacts:
> + path: build/logs/*.log
> + type: text/plain
prev parent reply other threads:[~2023-04-03 10:57 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-03 9:32 [kvm-unit-tests PATCH] ci: Provide the logs as artifacts Thomas Huth
2023-04-03 10:56 ` Claudio Imbrenda [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230403125646.18fe06f4@p-imbrenda \
--to=imbrenda@linux.ibm.com \
--cc=andrew.jones@linux.dev \
--cc=frankja@linux.ibm.com \
--cc=kvm@vger.kernel.org \
--cc=nrb@linux.ibm.com \
--cc=pbonzini@redhat.com \
--cc=thuth@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox