From patchwork Fri Jul 23 11:07:57 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 12395933 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-21.6 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,MENTIONS_GIT_HOSTING,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED, USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 33515C4338F for ; Fri, 23 Jul 2021 11:11:44 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id CDCE660EBC for ; Fri, 23 Jul 2021 11:11:43 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org CDCE660EBC Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=nongnu.org Received: from localhost ([::1]:49404 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m6t5j-0005vn-1C for qemu-devel@archiver.kernel.org; Fri, 23 Jul 2021 07:11:43 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37518) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m6t2M-0008H3-8w for qemu-devel@nongnu.org; Fri, 23 Jul 2021 07:08:14 -0400 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:28243) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m6t2K-0000ye-6W for qemu-devel@nongnu.org; Fri, 23 Jul 2021 07:08:14 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1627038491; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=uuNQOS7IFKHEZ6XIucVdSxVJJVJQXJSBvjsX07/cOh8=; b=YaUwKgd8JAeI6T6T6l5cyE4jRZkfRaHvZn6nIxbhu/OkEP2fAdLxxEBYZGn/SFXeXVanIS U6NGckHxiDsoo5/XdxmNO10sNn83Ovl8nMpuHC5Gmo9l1LzM8NZ43tFpablrVpwBJiIc54 HJ1NP3R0qNYqBDXX0JZg3uethHRONdw= Received: from mail-wm1-f70.google.com (mail-wm1-f70.google.com [209.85.128.70]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-231-vDLLeMmmMvKak4fw7JjI2g-1; Fri, 23 Jul 2021 07:08:08 -0400 X-MC-Unique: vDLLeMmmMvKak4fw7JjI2g-1 Received: by mail-wm1-f70.google.com with SMTP id k5-20020a7bc3050000b02901e081f69d80so92234wmj.8 for ; Fri, 23 Jul 2021 04:08:08 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=uuNQOS7IFKHEZ6XIucVdSxVJJVJQXJSBvjsX07/cOh8=; b=pRp+GxxFdy+f8ULO/PerK+OEBlAEzjPo3InPMK5zMoPpHZbFt6xRBWtisQ2ZLRaB3d zOhBAiTRiEsV3eegpb3rELjhWfxO/VtbmpH+SnlcUi6ds28FTMlgaBJOYVBVBa5QXSkf W11jmnLd0G+tOxahfyt2vqOnId0VscnEXmDk5pJJqUV0URx1olt2Cb88CJM+SjSV54Kk PYDys2TMhi5rHlk0JApIUA/ei7pI+g1Pv/XitvLJplUZSn1P6oC6NIfKWwVgslYIgkRe TpT23M7ome0brrOB8H802Lf3trwrlBIkG3Kn4GfP43ZuR5zk31tbEDbn+gJEQihIf3yb vYqw== X-Gm-Message-State: AOAM53279xbjzCQvzcJTe2myJA/A9HasvVGQmL9ij22+D1w2KujOHsCo 1FILLppjjE5+93HqNuLTVzLElDQyvVcJXqc6EPr6P+bUw7HkDj65U6SqfaSaN1sRdImPimAtjOQ TsEwbil+KpmYU+y/KbNyDY945MEYMq6UzbuzcS1pCJ4EcCrMHS2di2H2hfWrGIohU X-Received: by 2002:a5d:6d8f:: with SMTP id l15mr4676575wrs.158.1627038487386; Fri, 23 Jul 2021 04:08:07 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxP3mG+GuXTevCVV0LTYjQ9ixYNMx2XAwCl0CaOZlkJWlY6CY1X3JMumFu2kgTgoxcMWDjxZw== X-Received: by 2002:a5d:6d8f:: with SMTP id l15mr4676533wrs.158.1627038487135; Fri, 23 Jul 2021 04:08:07 -0700 (PDT) Received: from x1w.. (122.red-83-42-66.dynamicip.rima-tde.net. [83.42.66.122]) by smtp.gmail.com with ESMTPSA id z6sm5496223wmp.1.2021.07.23.04.08.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 23 Jul 2021 04:08:06 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Subject: [PATCH-for-6.1 v3 1/4] docs: Document GitLab custom CI/CD variables Date: Fri, 23 Jul 2021 13:07:57 +0200 Message-Id: <20210723110800.855648-2-philmd@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210723110800.855648-1-philmd@redhat.com> References: <20210723110800.855648-1-philmd@redhat.com> MIME-Version: 1.0 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=philmd@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Received-SPF: pass client-ip=216.205.24.124; envelope-from=philmd@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -42 X-Spam_score: -4.3 X-Spam_bar: ---- X-Spam_report: (-4.3 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-1.472, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Thomas Huth , =?utf-8?q?Daniel_P_=2E_Berrang=C3=A9?= , =?utf-8?q?Ale?= =?utf-8?q?x_Benn=C3=A9e?= , =?utf-8?q?Philippe_Math?= =?utf-8?q?ieu-Daud=C3=A9?= , Wainer dos Santos Moschetta , Willian Rampazzo , Bin Meng , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" We introduced the QEMU_CI_AVOCADO_TESTING variable in commit f56bf4caf ("gitlab: Run Avocado tests manually (except mainstream CI)"), but forgot to document it properly. Do it now. Suggested-by: Thomas Huth Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Daniel P. Berrangé --- docs/devel/ci.rst | 40 ++++++++++++++++++++++++++++++++++++++++ .gitlab-ci.yml | 19 ++----------------- 2 files changed, 42 insertions(+), 17 deletions(-) diff --git a/docs/devel/ci.rst b/docs/devel/ci.rst index b3bf3ef615b..53df04afb7f 100644 --- a/docs/devel/ci.rst +++ b/docs/devel/ci.rst @@ -8,6 +8,46 @@ found at:: https://wiki.qemu.org/Testing/CI +Custom CI/CD variables +====================== + +QEMU CI pipelines can be tuned setting some CI environment variables. + +Set variable globally in the user's CI namespace +------------------------------------------------ + +Variables can be set globally in the user's CI namespace setting. + +For further information about how to set these variables, please refer to:: + + https://docs.gitlab.com/ee/ci/variables/#create-a-custom-variable-in-the-ui + +Set variable manually when pushing a branch or tag to the user's repository +--------------------------------------------------------------------------- + +Variables can be set manually when pushing a branch or tag, using +git-push command line arguments. + +Example setting the QEMU_CI_EXAMPLE_VAR variable: + +.. code:: + + git push -o ci.variable="QEMU_CI_EXAMPLE_VAR=value" myrepo mybranch + +For further information about how to set these variables, please refer to:: + + https://docs.gitlab.com/ee/user/project/push_options.html#push-options-for-gitlab-cicd + +Here is a list of the most used variables: + +QEMU_CI_AVOCADO_TESTING +~~~~~~~~~~~~~~~~~~~~~~~ +By default, tests using the Avocado framework are not run automatically in +the pipelines (because multiple artifacts have to be downloaded, and if +these artifacts are not already cached, downloading them make the jobs +reach the timeout limit). Set this variable to have the tests using the +Avocado framework run automatically. + Jobs on Custom Runners ====================== diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 6dc5385e697..9762dda2ee3 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -16,24 +16,9 @@ # QEMU CI jobs are based on templates. Some templates provide # user-configurable options, modifiable via configuration variables. # -# These variables can be set globally in the user's CI namespace -# setting: -# https://docs.gitlab.com/ee/ci/variables/#create-a-custom-variable-in-the-ui -# or set manually each time a branch/tag is pushed, as a git-push -# command line argument: -# https://docs.gitlab.com/ee/user/project/push_options.html#push-options-for-gitlab-cicd +# See https://qemu-project.gitlab.io/qemu/devel/ci.html#custom-ci-cd-variables +# for more information. # -# Example setting the QEMU_CI_EXAMPLE_VAR variable: -# -# git push -o ci.variable="QEMU_CI_EXAMPLE_VAR=value" myrepo mybranch -# -# ---------------------------------------------------------------------- -# -# List of environment variables that can be use to modify the set -# of jobs selected: -# -# - QEMU_CI_AVOCADO_TESTING -# If set, tests using the Avocado framework will be run include: - local: '/.gitlab-ci.d/qemu-project.yml' From patchwork Fri Jul 23 11:07:58 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 12395869 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.6 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6A37BC4338F for ; Fri, 23 Jul 2021 11:09:50 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 0A48760E75 for ; Fri, 23 Jul 2021 11:09:50 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 0A48760E75 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=nongnu.org Received: from localhost ([::1]:43784 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m6t3t-00021x-4z for qemu-devel@archiver.kernel.org; Fri, 23 Jul 2021 07:09:49 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37540) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m6t2O-0008Kg-C5 for qemu-devel@nongnu.org; Fri, 23 Jul 2021 07:08:16 -0400 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:48141) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m6t2M-00010r-QK for qemu-devel@nongnu.org; Fri, 23 Jul 2021 07:08:16 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1627038494; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=v8MzHpNZAnKpENgpYi7cnpOvXuv0pKcpWhVnCTIEAsU=; b=OyAGK3sd2uw7bWmckZFNXj8q1/J0Zf5wO/n6oyy+W4ebh7ayyNrrs0jtttOI09sBGbai36 JUFErG0E9tLGog1D7Ncv249Ww6NQ0U2WvugPxBDricJREhsDGhvit04DyLCiQyn26XNaqE cnshmoGv+7T7vjc/nvBaK/UFSxVhetQ= Received: from mail-wr1-f71.google.com (mail-wr1-f71.google.com [209.85.221.71]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-123-wszEulpCOSmQUs-uYTuHVQ-1; Fri, 23 Jul 2021 07:08:13 -0400 X-MC-Unique: wszEulpCOSmQUs-uYTuHVQ-1 Received: by mail-wr1-f71.google.com with SMTP id u11-20020a5d434b0000b029013e2027cf9aso859379wrr.9 for ; Fri, 23 Jul 2021 04:08:13 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=v8MzHpNZAnKpENgpYi7cnpOvXuv0pKcpWhVnCTIEAsU=; b=Mg9bnMiW8g6aPOogjTQJBquvZviCUaCVcdmk69JxRvrsnEIaUPUObd1x+nxy3uVWcD hW9Ks9F4lDJoUFG9Qy4nPI2jhEN/LG1P5T43WpE5gpeN/3SB9JEzo8r0VnFXKOB5EYzH uM63wpUMj8Cw53+jxdOW+oy/no0L1uAaoljGYPZpd3+rcWZIbWtci4iNEXQsuPh5j/i3 gI7zfa0XGT1HV1Epu/Nsd9DgiCMUHZC53t3kG3wAixjNIQ9rzNJgneBz3X6cq/DKQJaF UEvDk0TkLbDmeJaUtJ0g2NqK6vWDFVGgvWjt4Qt6KZjo7nlaeXPQ57KvjdHriONo4Z7A dckw== X-Gm-Message-State: AOAM533o8i67pxHbTExNUqw5kIAPN/HpJMi6FsDkIUK1H20si7/16eUm Jk7yjlCws5G5cbeLG0I8rLsn7tBOEggsZ6VA4ymTjDl7PzRGvRWGW0qTewEIDOCYqvyxpc8RLE1 w/asj+yrwN4IBD5FgUdiVWQNIClMSChZ6zUz5qAXo9X+YmYzsrRb2QE1t0Q4J7Y1j X-Received: by 2002:a5d:4010:: with SMTP id n16mr4703110wrp.142.1627038491958; Fri, 23 Jul 2021 04:08:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxyzxjfYrFb6YXdKI3FuaKZZGzKz5awc0OnzJj5PlESIoVPcV1ZPhyUj/nONmLtDglRp+09MA== X-Received: by 2002:a5d:4010:: with SMTP id n16mr4703072wrp.142.1627038491670; Fri, 23 Jul 2021 04:08:11 -0700 (PDT) Received: from x1w.. (122.red-83-42-66.dynamicip.rima-tde.net. [83.42.66.122]) by smtp.gmail.com with ESMTPSA id d203sm179149wmd.38.2021.07.23.04.08.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 23 Jul 2021 04:08:11 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Subject: [PATCH-for-6.1 v3 2/4] gitlab-ci: Fix 'when:' condition in acceptance_test_job_template Date: Fri, 23 Jul 2021 13:07:58 +0200 Message-Id: <20210723110800.855648-3-philmd@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210723110800.855648-1-philmd@redhat.com> References: <20210723110800.855648-1-philmd@redhat.com> MIME-Version: 1.0 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=philmd@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Received-SPF: pass client-ip=216.205.24.124; envelope-from=philmd@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -42 X-Spam_score: -4.3 X-Spam_bar: ---- X-Spam_report: (-4.3 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-1.472, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Thomas Huth , =?utf-8?q?Daniel_P_=2E_Berrang=C3=A9?= , =?utf-8?q?Ale?= =?utf-8?q?x_Benn=C3=A9e?= , =?utf-8?q?Philippe_Math?= =?utf-8?q?ieu-Daud=C3=A9?= , Wainer dos Santos Moschetta , Willian Rampazzo , Bin Meng , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" Jobs depending on another should not use the 'when: always' condition, because if a dependency failed we should not keep running jobs depending on it. The correct condition is 'when: on_success'. Fixes: f56bf4caf71 ("gitlab: Run Avocado tests manually (except mainstream CI)") Reported-by: Daniel P. Berrangé Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Daniel P. Berrangé --- .gitlab-ci.d/buildtest-template.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitlab-ci.d/buildtest-template.yml b/.gitlab-ci.d/buildtest-template.yml index 3e3e19d96bd..fcbcc4e627a 100644 --- a/.gitlab-ci.d/buildtest-template.yml +++ b/.gitlab-ci.d/buildtest-template.yml @@ -73,9 +73,9 @@ # in its namespace setting or via git-push option, see documentation # in /.gitlab-ci.yml of this repository). - if: '$CI_PROJECT_NAMESPACE == "qemu-project"' - when: always + when: on_success - if: '$QEMU_CI_AVOCADO_TESTING' - when: always + when: on_success # Otherwise, set to manual (the jobs are created but not run). - when: manual allow_failure: true From patchwork Fri Jul 23 11:07:59 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 12395931 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.6 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A2FD2C4338F for ; Fri, 23 Jul 2021 11:10:07 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 63A2F60725 for ; Fri, 23 Jul 2021 11:10:07 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 63A2F60725 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=nongnu.org Received: from localhost ([::1]:44176 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m6t49-0002H9-0V for qemu-devel@archiver.kernel.org; Fri, 23 Jul 2021 07:10:05 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37562) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m6t2S-0008UL-NX for qemu-devel@nongnu.org; Fri, 23 Jul 2021 07:08:20 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:29284) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m6t2R-00014q-9h for qemu-devel@nongnu.org; Fri, 23 Jul 2021 07:08:20 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1627038498; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=XidfJlF9uLw0ONlJoTjRYGZYc29iEXG+CBqqwyBgpGk=; b=H26cPRA2T9rYZv0qxcfkmkssvWgnOiP5ZBj1wrWExX+29DcOFlYptvN3J7C1Nga2RWWY48 ewElNWPqtlMEGv3ePyBNP98xjpF8Cs1PI7lyWpNd8q10gj1AzeOmvnuiiRHtYBHwua6DfM fZaCMu3fIF0fAf6v1A0mAbB0TBtL6Aw= Received: from mail-wr1-f69.google.com (mail-wr1-f69.google.com [209.85.221.69]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-42-SedXIzv7M76sCl5MK_DsXQ-1; Fri, 23 Jul 2021 07:08:17 -0400 X-MC-Unique: SedXIzv7M76sCl5MK_DsXQ-1 Received: by mail-wr1-f69.google.com with SMTP id p12-20020a5d68cc0000b02901426384855aso856773wrw.11 for ; Fri, 23 Jul 2021 04:08:17 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=XidfJlF9uLw0ONlJoTjRYGZYc29iEXG+CBqqwyBgpGk=; b=I4/dN9LCbdwUD9tv9p0iJ2KoU4oQ2PJ27b0rerK+EAOFMA3d20LtCh+1hW4yHaeMi7 mzvxtcoqrms6WLNNbeDgqHPT6Ov+am16AMmBgV6JaI+r8WIAS9SAtV+L/bedq9fcq28y 2T8zQ4rQK7sC0xkjQ3I9dSB0ZiGsLbUua5PzdfRV3PqXtHcA5vT6LF3touJmZjUfeoCl HVrNdYJX9obE8CzLV8YZ4xmPx4HKxl6mmOm/J2mVQPNn+c8d/tza1bUryhFoEwoodogF 8+zRmsqzw4ajoujxB/xcZYMggux1uJls17hEXq2Ucw9Vczcwu074vk0cMO4wKeJUuCJV ZyQQ== X-Gm-Message-State: AOAM5312Zh5VnhzMosxHNpeq7NJt9XclTmV0FE3H2hq2OH4EBVMC1qau lOCHk6W64RuBS6g454Db6WN/hu7DFKEAF1d9ROqDQ5LLdg/gQJ96x9ub7aG0mJ9ilZ00dxlGhS7 Ztfayjp0rbotGZa5sIvbQj4gZi+o/TU0+IOFZWfnDvkn3i4YlMXAwcCewyGHIEouJ X-Received: by 2002:a1c:1dcf:: with SMTP id d198mr243047wmd.103.1627038496383; Fri, 23 Jul 2021 04:08:16 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyev2IvkcNXfbbBaa+H25DPErEH/dkOuryws+ARsaH/OFnHtfOHxpbWWxNt84luxEZ2GYPKww== X-Received: by 2002:a1c:1dcf:: with SMTP id d198mr243018wmd.103.1627038496162; Fri, 23 Jul 2021 04:08:16 -0700 (PDT) Received: from x1w.. (122.red-83-42-66.dynamicip.rima-tde.net. [83.42.66.122]) by smtp.gmail.com with ESMTPSA id a10sm32157785wrm.12.2021.07.23.04.08.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 23 Jul 2021 04:08:15 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Subject: [PATCH-for-6.1 v3 3/4] gitlab-ci: Fix 'when:' condition in EDK2 jobs Date: Fri, 23 Jul 2021 13:07:59 +0200 Message-Id: <20210723110800.855648-4-philmd@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210723110800.855648-1-philmd@redhat.com> References: <20210723110800.855648-1-philmd@redhat.com> MIME-Version: 1.0 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=philmd@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Received-SPF: pass client-ip=170.10.133.124; envelope-from=philmd@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -42 X-Spam_score: -4.3 X-Spam_bar: ---- X-Spam_report: (-4.3 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-1.472, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Thomas Huth , =?utf-8?q?Daniel_P_=2E_Berrang=C3=A9?= , =?utf-8?q?Ale?= =?utf-8?q?x_Benn=C3=A9e?= , =?utf-8?q?Philippe_Math?= =?utf-8?q?ieu-Daud=C3=A9?= , Wainer dos Santos Moschetta , Willian Rampazzo , Bin Meng , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" Jobs depending on another should not use the 'when: always' condition, because if a dependency failed we should not keep running jobs depending on it. The correct condition is 'when: on_success'. Fixes: 71920809cea ("gitlab-ci.yml: Add jobs to build EDK2 firmware binaries") Reported-by: Daniel P. Berrangé Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Daniel P. Berrangé --- .gitlab-ci.d/edk2.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.gitlab-ci.d/edk2.yml b/.gitlab-ci.d/edk2.yml index aae2f7ad880..62497ba47fb 100644 --- a/.gitlab-ci.d/edk2.yml +++ b/.gitlab-ci.d/edk2.yml @@ -8,11 +8,11 @@ - .gitlab-ci.d/edk2/Dockerfile # or roms/edk2/ is modified (submodule updated) - roms/edk2/* - when: always + when: on_success - if: '$CI_COMMIT_REF_NAME =~ /^edk2/' # or the branch/tag starts with 'edk2' - when: always + when: on_success - if: '$CI_COMMIT_MESSAGE =~ /edk2/i' # or last commit description contains 'EDK2' - when: always + when: on_success docker-edk2: extends: .edk2_job_rules From patchwork Fri Jul 23 11:08:00 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= X-Patchwork-Id: 12395935 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-16.6 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 21A2EC4338F for ; Fri, 23 Jul 2021 11:12:30 +0000 (UTC) Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 7E59E60E75 for ; Fri, 23 Jul 2021 11:12:29 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 7E59E60E75 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=redhat.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=nongnu.org Received: from localhost ([::1]:50850 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1m6t6S-0006vk-O1 for qemu-devel@archiver.kernel.org; Fri, 23 Jul 2021 07:12:28 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:37590) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m6t2b-0000Gj-51 for qemu-devel@nongnu.org; Fri, 23 Jul 2021 07:08:29 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:56511) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1m6t2Y-00019l-0X for qemu-devel@nongnu.org; Fri, 23 Jul 2021 07:08:28 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1627038505; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=MgVf1UaIIsKpWFBNlJub9Vl0Re2X6ZB97rXqZyhYWzE=; b=UdOGmKpLEkDePHb32l8o5dO4bl8CMfvWX6pf/CqkonHpzbVNvgcj6d5tXUFHQvlLL57ZOk DHY00lHAehYYMJV/nTT9pu7vXEMOygTm6+Eo1Tq0t6q0vqLgqsKgHE6FT17j5AgYM9riPY fI7o+VWWrOivgYL548xT4Jjgf7jHqr8= Received: from mail-wm1-f69.google.com (mail-wm1-f69.google.com [209.85.128.69]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-302-sX_Bghu6MWyrvkl6xN5DSQ-1; Fri, 23 Jul 2021 07:08:22 -0400 X-MC-Unique: sX_Bghu6MWyrvkl6xN5DSQ-1 Received: by mail-wm1-f69.google.com with SMTP id o25-20020a05600c5119b0290218757e2783so663658wms.7 for ; Fri, 23 Jul 2021 04:08:22 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=MgVf1UaIIsKpWFBNlJub9Vl0Re2X6ZB97rXqZyhYWzE=; b=UgEtsYT+vz6tV/XO8Z7wjpcvqZk2hLQOg0Njot1MFeOOdQKoCGLS16SQ4+9NAeGpFO NqcrAC5kltUui2WSZ7AZUxlm01X+S00aUvQlGO2R7jWm6WGamW2/YizJ1gfSIc+sOlwm KDYMUbYXR2y69bUMt/0XJwx+j5FWtMiWQejf2f0YfOKiC1EymBgo7y7eAuc2BSGb+4Ga yFu5XTuSlBmiBg5nzEE5umfkwuRc3x5tfoKIfYAFROo2gnf613ZEUWf5P2LwonfRPFDi jBExf3vBlCkUorBP/jn8u6kpK95P2SIH6DYhgzOOFqBFfN7nGK1hnrOfbTd7rb/NxH1n 6tYA== X-Gm-Message-State: AOAM533Zz7XosiOVL2SAWDmcHk6+T05ikI7jL/kR2fz2Dgp15sLmYP2v FjXmSQd7RxbehQ8fXR96lL7Cu+JeqvbQLDgEoYhUS8epai4YOMHgh4TtDTkK8gOeBI+WLzhzeNR 4g0Tx0GLG+6cjgUJYgsNqApZ4jduJp67N4gKuAaz8n3+yBCTyDTOp/IeiWfHSp61M X-Received: by 2002:a1c:ed13:: with SMTP id l19mr3073089wmh.48.1627038500990; Fri, 23 Jul 2021 04:08:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwTeCidQNnCLQKQpmyQxSYsy+smZFue4QXZlkNqt7Ushhzmbf5mLwkaAy1HjJXHA5ceypXOzg== X-Received: by 2002:a1c:ed13:: with SMTP id l19mr3073053wmh.48.1627038500683; Fri, 23 Jul 2021 04:08:20 -0700 (PDT) Received: from x1w.. (122.red-83-42-66.dynamicip.rima-tde.net. [83.42.66.122]) by smtp.gmail.com with ESMTPSA id d5sm542167wre.77.2021.07.23.04.08.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 23 Jul 2021 04:08:20 -0700 (PDT) From: =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= To: qemu-devel@nongnu.org Subject: [PATCH-for-6.1 v3 4/4] gitlab-ci: Extract OpenSBI job rules and fix 'when:' condition Date: Fri, 23 Jul 2021 13:08:00 +0200 Message-Id: <20210723110800.855648-5-philmd@redhat.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210723110800.855648-1-philmd@redhat.com> References: <20210723110800.855648-1-philmd@redhat.com> MIME-Version: 1.0 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=philmd@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Received-SPF: pass client-ip=170.10.133.124; envelope-from=philmd@redhat.com; helo=us-smtp-delivery-124.mimecast.com X-Spam_score_int: -42 X-Spam_score: -4.3 X-Spam_bar: ---- X-Spam_report: (-4.3 / 5.0 requ) BAYES_00=-1.9, DKIMWL_WL_HIGH=-1.472, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Thomas Huth , =?utf-8?q?Daniel_P_=2E_Berrang=C3=A9?= , =?utf-8?q?Ale?= =?utf-8?q?x_Benn=C3=A9e?= , =?utf-8?q?Philippe_Math?= =?utf-8?q?ieu-Daud=C3=A9?= , Wainer dos Santos Moschetta , Willian Rampazzo , Cleber Rosa , Bin Meng , =?utf-8?q?Philippe_Mathieu-Daud=C3=A9?= Errors-To: qemu-devel-bounces+qemu-devel=archiver.kernel.org@nongnu.org Sender: "Qemu-devel" First, all jobs depending on 'docker-opensbi' job must use at most all the rules that triggers it. The simplest way to ensure that is to always use the same rules. Extract all the rules to a reusable section, and include this section (with the 'extends' keyword) in both 'docker-opensbi' and 'build-opensbi' jobs. Second, jobs depending on another should not use the 'when: always' condition, because if a dependency failed we should not keep running jobs depending on it. The correct condition is 'when: on_success'. The problems were introduced in commit c6fc0fc1a71 ("gitlab-ci.yml: Add jobs to build OpenSBI firmware binaries"), but were revealed in commit 91e9c47e50a ("docker: OpenSBI build job depends on OpenSBI container"). This fix is similar to the one used with the EDK2 firmware job in commit ac0595cf6b3 ("gitlab-ci: Extract EDK2 job rules to reusable section"). Reported-by: Daniel P. Berrangé Reviewed-by: Daniel P. Berrangé Reviewed-by: Willian Rampazzo Reviewed-by: Cleber Rosa Signed-off-by: Philippe Mathieu-Daudé --- .gitlab-ci.d/opensbi.yml | 30 ++++++++++++++++++------------ 1 file changed, 18 insertions(+), 12 deletions(-) diff --git a/.gitlab-ci.d/opensbi.yml b/.gitlab-ci.d/opensbi.yml index f66cd1d9089..5e0a2477c5d 100644 --- a/.gitlab-ci.d/opensbi.yml +++ b/.gitlab-ci.d/opensbi.yml @@ -1,10 +1,23 @@ -docker-opensbi: - stage: containers - rules: # Only run this job when the Dockerfile is modified +# All jobs needing docker-opensbi must use the same rules it uses. +.opensbi_job_rules: + rules: # Only run this job when ... - changes: + # this file is modified - .gitlab-ci.d/opensbi.yml + # or the Dockerfile is modified - .gitlab-ci.d/opensbi/Dockerfile - when: always + when: on_success + - changes: # or roms/opensbi/ is modified (submodule updated) + - roms/opensbi/* + when: on_success + - if: '$CI_COMMIT_REF_NAME =~ /^opensbi/' # or the branch/tag starts with 'opensbi' + when: on_success + - if: '$CI_COMMIT_MESSAGE =~ /opensbi/i' # or last commit description contains 'OpenSBI' + when: on_success + +docker-opensbi: + extends: .opensbi_job_rules + stage: containers image: docker:19.03.1 services: - docker:19.03.1-dind @@ -24,16 +37,9 @@ docker-opensbi: - docker push $IMAGE_TAG build-opensbi: + extends: .opensbi_job_rules stage: build needs: ['docker-opensbi'] - rules: # Only run this job when ... - - changes: # ... roms/opensbi/ is modified (submodule updated) - - roms/opensbi/* - when: always - - if: '$CI_COMMIT_REF_NAME =~ /^opensbi/' # or the branch/tag starts with 'opensbi' - when: always - - if: '$CI_COMMIT_MESSAGE =~ /opensbi/i' # or last commit description contains 'OpenSBI' - when: always artifacts: paths: # 'artifacts.zip' will contains the following files: - pc-bios/opensbi-riscv32-generic-fw_dynamic.bin