summaryrefslogtreecommitdiffstats
path: root/scripts/ci
Commit message (Collapse)AuthorAgeFilesLines
* scripts/ci: allow for a secondary runnerAlex Bennée2022-02-281-0/+38
| | | | | | | | | | Some HW can run multiple architecture profiles so we can install a secondary runner to build and run tests for those profiles. This allows setting up secondary service. Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Acked-by: Richard Henderson <richard.henderson@linaro.org> Message-Id: <20220225172021.3493923-9-alex.bennee@linaro.org>
* scripts/ci: add build env rules for aarch32 on aarch64Alex Bennée2022-02-281-0/+25
| | | | | | | | | | | | | At least the current crop of Aarch64 HW can support running 32 bit EL0 code. Before we can build and test we need a minimal set of packages installed. We can't use "apt build-dep" because it currently gets confused trying to keep two sets of build-deps installed at once. Instead we install a minimal set of libraries that will allow us to continue. Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Richard Henderson <richard.henderson@linaro.org> Message-Id: <20220225172021.3493923-8-alex.bennee@linaro.org>
* drop libxml2 checks since libxml is not actually used (for parallels)Michael Tokarev2022-02-091-1/+0Star
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For a long time, we assumed that libxml2 is necessary for parallels block format support (block/parallels*). However, this format actually does not use libxml [*]. Since this is the only user of libxml2 in whole QEMU tree, we can drop all libxml2 checks and dependencies too. It is even more: --enable-parallels configure option was the only option which was silently ignored when it's (fake) dependency (libxml2) isn't installed. Drop all mentions of libxml2. [*] Actually the basis for libxml use were introduced in commit ed279a06c53 ("configure: add dependency") but the implementation was never merged: https://lore.kernel.org/qemu-devel/70227bbd-a517-70e9-714f-e6e0ec431be9@openvz.org/ Signed-off-by: Michael Tokarev <mjt@tls.msk.ru> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Message-Id: <20220119090423.149315-1-mjt@msgid.tls.msk.ru> Tested-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> [PMD: Updated description and adapted to use lcitool] Reviewed-by: Thomas Huth <thuth@redhat.com> Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Message-Id: <20220121154134.315047-5-f4bug@amsat.org> Reviewed-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com> Message-Id: <20220204204335.1689602-9-alex.bennee@linaro.org>
* block/file-posix: Simplify the XFS_IOC_DIOINFO handlingThomas Huth2022-01-121-1/+0Star
| | | | | | | | | | | | | | | | | | | The handling for the XFS_IOC_DIOINFO ioctl is currently quite excessive: This is not a "real" feature like the other features that we provide with the "--enable-xxx" and "--disable-xxx" switches for the configure script, since this does not influence lots of code (it's only about one call to xfsctl() in file-posix.c), so people don't gain much with the ability to disable this with "--disable-xfsctl". It's also unfortunate that the ioctl will be disabled on Linux in case the user did not install the right xfsprogs-devel package before running configure. Thus let's simplify this by providing the ioctl definition on our own, so we can completely get rid of the header dependency and thus the related code in the configure script. Suggested-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com> Message-Id: <20211215125824.250091-1-thuth@redhat.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
* Jobs based on custom runners: add CentOS Stream 8Cleber Rosa2021-11-165-0/+384
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This introduces three different parts of a job designed to run on a custom runner managed by Red Hat. The goals include: a) propose a model for other organizations that want to onboard their own runners, with their specific platforms, build configuration and tests. b) bring awareness to the differences between upstream QEMU and the version available under CentOS Stream, which is "A preview of upcoming Red Hat Enterprise Linux minor and major releases". c) because of b), it should be easier to identify and reduce the gap between Red Hat's downstream and upstream QEMU. The components of this custom job are: I) OS build environment setup code: - additions to the existing "build-environment.yml" playbook that can be used to set up CentOS/EL 8 systems. - a CentOS Stream 8 specific "build-environment.yml" playbook that adds to the generic one. II) QEMU build configuration: a script that will produce binaries with features as similar as possible to the ones built and packaged on CentOS stream 8. III) Scripts that define the minimum amount of testing that the binaries built with the given configuration (point II) under the given OS build environment (point I) should be subjected to. IV) Job definition: GitLab CI jobs that will dispatch the build/test jobs (see points #II and #III) to the machine specifically configured according to #I. Signed-off-by: Cleber Rosa <crosa@redhat.com> Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Willian Rampazzo <willianr@redhat.com> Tested-by: Willian Rampazzo <willianr@redhat.com> Message-Id: <20211111160501.862396-2-crosa@redhat.com> Message-Id: <20211115142915.3797652-6-alex.bennee@linaro.org>
* Jobs based on custom runners: docs and gitlab-runner setup playbookCleber Rosa2021-07-143-1/+84
| | | | | | | | | | | | | | | | | | | | | | | | | | | | To have the jobs dispatched to custom runners, gitlab-runner must be installed, active as a service and properly configured. The variables file and playbook introduced here should help with those steps. The playbook introduced here covers the Linux distributions and has been primarily tested on OS/machines that the QEMU project has available to act as runners, namely: * Ubuntu 20.04 on aarch64 * Ubuntu 18.04 on s390x But, it should work on all other Linux distributions. Earlier versions were tested on FreeBSD too, so chances of success are high. Signed-off-by: Cleber Rosa <crosa@redhat.com> Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Tested-by: Willian Rampazzo <willianr@redhat.com> Tested-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Willian Rampazzo <willianr@redhat.com> Reviewed-by: Wainer dos Santos Moschetta <wainersm@redhat.com> Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Message-Id: <20210630012619.115262-4-crosa@redhat.com> Message-Id: <20210709143005.1554-4-alex.bennee@linaro.org>
* Jobs based on custom runners: build environment docs and playbookCleber Rosa2021-07-143-0/+119
| | | | | | | | | | | | | | | | | | | | To run basic jobs on custom runners, the environment needs to be properly set up. The most common requirement is having the right packages installed. The playbook introduced here covers the QEMU's project s390x and aarch64 machines. At the time this is being proposed, those machines have already had this playbook applied to them. Signed-off-by: Cleber Rosa <crosa@redhat.com> Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Tested-by: Alex Bennée <alex.bennee@linaro.org> Tested-by: Willian Rampazzo <willianr@redhat.com> Reviewed-by: Wainer dos Santos Moschetta <wainersm@redhat.com> Reviewed-by: Willian Rampazzo <willianr@redhat.com> Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Message-Id: <20210630012619.115262-3-crosa@redhat.com> Message-Id: <20210709143005.1554-3-alex.bennee@linaro.org>
* scripts/ci/gitlab-pipeline-status: give more info when pipeline not foundCleber Rosa2021-03-091-1/+3
| | | | | | | | | | This includes both input parameters (project id and commit) in the message so to make it easier to debug returned API calls. Signed-off-by: Cleber Rosa <crosa@redhat.com> Reviewed-by: Wainer dos Santos Moschetta <wainersm@redhat.com> Message-Id: <20210222193240.921250-4-crosa@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
* scripts/ci/gitlab-pipeline-status: give more information on failuresCleber Rosa2021-03-091-1/+3
| | | | | | | | | | | When an HTTP GET request fails, it's useful to go beyond the "not successful" message, and show the code returned by the server. Signed-off-by: Cleber Rosa <crosa@redhat.com> Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Wainer dos Santos Moschetta <wainersm@redhat.com> Message-Id: <20210222193240.921250-3-crosa@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
* scripts/ci/gitlab-pipeline-status: split utlity function for HTTP GETCleber Rosa2021-03-091-5/+12
| | | | | | | | | | | This simply splits out the code that does an HTTP GET so that it can be used for other API requests. Signed-off-by: Cleber Rosa <crosa@redhat.com> Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Wainer dos Santos Moschetta <wainersm@redhat.com> Message-Id: <20210222193240.921250-2-crosa@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
* travis.yml: Move gprof/gcov test across to gitlabPhilippe Mathieu-Daudé2021-02-151-0/+27
| | | | | | | | | | | | | | | | | | | | Similarly to commit 8cdb2cef3f1, move the gprof/gcov test to GitLab. The coverage-summary.sh script is not Travis-CI specific, make it generic. [thuth: Add gcovr and bsdmainutils which are required for the coverage-summary.sh script to the ubuntu docker file, and use 'check' as test target] Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com> Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Wainer dos Santos Moschetta <wainersm@redhat.com> Message-Id: <20201108204535.2319870-10-philmd@redhat.com> Message-Id: <20210211045455.456371-2-thuth@redhat.com> Message-Id: <20210211122750.22645-2-alex.bennee@linaro.org>
* scripts/ci: clean up default args logic a littleAlex Bennée2020-11-231-11/+13
| | | | | | | | | | | | This allows us to do: ./scripts/ci/gitlab-pipeline-status -w -b HEAD -p 2961854 to check out own pipeline status of a recently pushed branch. Signed-off-by: Alex Bennée <alex.bennee@linaro.org> Reviewed-by: Wainer dos Santos Moschetta <wainersm@redhat.com> Message-Id: <20201117173635.29101-2-alex.bennee@linaro.org>
* scripts/ci/gitlab-pipeline-status: wait for pipeline creationCleber Rosa2020-10-131-4/+13
| | | | | | | | | | | When called in wait mode, this script will also wait for the pipeline to be get to a "running" state. Because many more status may be seen until a pipeline gets to "running", and those need to be handle too. Reference: https://docs.gitlab.com/ee/api/pipelines.html#list-project-pipelines Signed-off-by: Cleber Rosa <crosa@redhat.com> Message-Id: <20200904164258.240278-8-crosa@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
* scripts/ci/gitlab-pipeline-status: use more descriptive exceptionsCleber Rosa2020-10-131-2/+10
| | | | | | | | For two very different error conditions. Signed-off-by: Cleber Rosa <crosa@redhat.com> Message-Id: <20200904164258.240278-7-crosa@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
* scripts/ci/gitlab-pipeline-status: handle keyboard interruptsCleber Rosa2020-10-131-2/+4
| | | | | | | | So that exits based on user requests are handled more gracefully. Signed-off-by: Cleber Rosa <crosa@redhat.com> Message-Id: <20200904164258.240278-6-crosa@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
* scripts/ci/gitlab-pipeline-status: refactor parser creationCleber Rosa2020-10-131-4/+7
| | | | | | | | Out of the main function. Signed-off-by: Cleber Rosa <crosa@redhat.com> Message-Id: <20200904164258.240278-5-crosa@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
* scripts/ci/gitlab-pipeline-status: give early feedback on running pipelinesCleber Rosa2020-10-131-1/+1
| | | | | | | | | | | | | When waiting for a pipeline to run and finish, it's better to give early feedback, and then sleep and wait, than the other wait around. Specially for the first iteration, it's frustrating to see nothing while the script is sleeping. Signed-off-by: Cleber Rosa <crosa@redhat.com> Message-Id: <20200904164258.240278-4-crosa@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
* scripts/ci/gitlab-pipeline-status: improve message regarding timeoutCleber Rosa2020-10-131-1/+4
| | | | | | | | | | | | The script has its own timeout, which is about how long the script will wait (when called with --wait) for the pipeline to complete, and not necessarily for the pipeline to complete. Hopefully this new wording will be clearer. Signed-off-by: Cleber Rosa <crosa@redhat.com> Message-Id: <20200904164258.240278-3-crosa@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
* scripts/ci/gitlab-pipeline-status: make branch name configurableCleber Rosa2020-10-131-6/+6
| | | | | | | | | | | | With the utility function `get_local_staging_branch_commit()`, the name of the branch is hard coded (including in the function name). For extensibility reasons, let's make that configurable. Signed-off-by: Cleber Rosa <crosa@redhat.com> Message-Id: <20200904164258.240278-2-crosa@redhat.com> Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
* GitLab Gating CI: introduce pipeline-status contrib scriptCleber Rosa2020-07-131-0/+157
This script is intended to be used right after a push to a branch. By default, it will look for the pipeline associated with the commit that is the HEAD of the *local* staging branch. It can be used as a one time check, or with the `--wait` option to wait until the pipeline completes. If the pipeline is successful, then a merge of the staging branch into the master branch should be the next step. Signed-off-by: Cleber Rosa <crosa@redhat.com> Message-Id: <20200709024657.2500558-2-crosa@redhat.com> [thuth: Added the changes suggested by Erik Skultety] Signed-off-by: Thomas Huth <thuth@redhat.com>