From nobody Sun May 5 11:12:02 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zoho.com; dkim=fail spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1496244097177560.363757309496; Wed, 31 May 2017 08:21:37 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 0F51E7F6AC; Wed, 31 May 2017 15:21:33 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id DDC5E18A27; Wed, 31 May 2017 15:21:32 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 8CBC4180BAF5; Wed, 31 May 2017 15:21:32 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v4VFLVm2025438 for ; Wed, 31 May 2017 11:21:31 -0400 Received: by smtp.corp.redhat.com (Postfix) id 26844784B3; Wed, 31 May 2017 15:21:31 +0000 (UTC) Received: from mx1.redhat.com (ext-mx07.extmail.prod.ext.phx2.redhat.com [10.5.110.31]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 1D64580E65 for ; Wed, 31 May 2017 15:21:27 +0000 (UTC) Received: from mail-qk0-f193.google.com (mail-qk0-f193.google.com [209.85.220.193]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 61077C04B920 for ; Wed, 31 May 2017 15:21:26 +0000 (UTC) Received: by mail-qk0-f193.google.com with SMTP id y128so2210406qka.3 for ; Wed, 31 May 2017 08:21:26 -0700 (PDT) Received: from localhost.localdomain ([189.103.224.91]) by smtp.gmail.com with ESMTPSA id x31sm10873159qtx.12.2017.05.31.08.21.21 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 31 May 2017 08:21:24 -0700 (PDT) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 0F51E7F6AC Authentication-Results: ext-mx01.extmail.prod.ext.phx2.redhat.com; dmarc=fail (p=none dis=none) header.from=gmail.com Authentication-Results: ext-mx01.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=libvir-list-bounces@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 0F51E7F6AC Authentication-Results: mx1.redhat.com; dkim=fail reason="signature verification failed" (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="FGF4bTVp" DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 61077C04B920 Authentication-Results: ext-mx07.extmail.prod.ext.phx2.redhat.com; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: ext-mx07.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=claudioandre.br@gmail.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 61077C04B920 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=PxPap2iugXnmRcZMcOZ4KVHG1ybpOsZ0z7F4FRD0DqI=; b=FGF4bTVpjgdaj0t97hfohkKw+SyAX+xN+C1SH02Rpz2xxVO+KBi4rp/cG6xUkUrq1v OkTPob7lWdN0MkdeXJxXzc4kHPO0jtMeM4WldOrQMrp3OvYitmA2RDTeAqKT9TSvodSa ryH3hNRk9i23gAA8JsoAUcaCliJteyXyG6pE2bqrR6a3sdMkpHLZmnOW6/2sqkW5T0x8 KwC8YGcUNxXpc9wIkC2yb00y1XbujE+r89sOByi6h9aCT/RgbCUm9Xh1FbhuHvUxw5tU ex+S+BdBwXphKnXYTiFxT1vRIOD6iY372rss/lAZVbeTNHqJE3f9lJoBTHbRhmu1UzTk JRMg== 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:mime-version :content-transfer-encoding; bh=PxPap2iugXnmRcZMcOZ4KVHG1ybpOsZ0z7F4FRD0DqI=; b=BhL0ckUB5zht4v23j32JNdIW6+Uk6P7jLImM3udRJw2U948U48L1mIkcaaAnSQnRTc mCGuI/K14cAT915Gl5lgMRcWrxHctuf7pQN4Ab0D5k/vrYqaXTXqzvVOhHvFTsXZNRai a+cQQb+VNqbcJ6/dDjCnqtLCYsoK8dxj3AJYSOhHJm7jxrXUO9df1HspSVYttA4+Lc08 tr0RfZDcjNlYKT1Xx8ovhahmEs2osSwuTxEIE8Js9NtGSno2IPYHxHbP60r3szettQ5a 89NLk7VnnFtJKgdY35+lbXHxnu5DeZ9dVKxMMYTsaAU1cg6VvJ6Cm8iXsBN+9REUOVvM 9lNg== X-Gm-Message-State: AODbwcBNb3+xENJADAuWxp/g6G1Gg1btL6+LNmc0EKyp0YzehYNGchb/ n4OKx6UgJb45ZUvz X-Received: by 10.233.223.196 with SMTP id t187mr30817112qkf.31.1496244085493; Wed, 31 May 2017 08:21:25 -0700 (PDT) From: claudioandre.br@gmail.com To: libvir-list@redhat.com Date: Wed, 31 May 2017 12:21:05 -0300 Message-Id: <20170531152105.17869-1-claudioandre.br@gmail.com> MIME-Version: 1.0 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.31]); Wed, 31 May 2017 15:21:26 +0000 (UTC) X-Greylist: inspected by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.31]); Wed, 31 May 2017 15:21:26 +0000 (UTC) for IP:'209.85.220.193' DOMAIN:'mail-qk0-f193.google.com' HELO:'mail-qk0-f193.google.com' FROM:'claudioandre.br@gmail.com' RCPT:'' X-RedHat-Spam-Score: 2.67 ** (BAYES_50, DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, RCVD_IN_SORBS_SPAM, RCVD_IN_SORBS_WEB, SPF_PASS) 209.85.220.193 mail-qk0-f193.google.com 209.85.220.193 mail-qk0-f193.google.com X-Scanned-By: MIMEDefang 2.78 on 10.5.110.31 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 X-loop: libvir-list@redhat.com Cc: =?UTF-8?q?Claudio=20Andr=C3=A9?= Subject: [libvirt] [PATCH V2] CI: also run tests using updated distro(s) X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.25]); Wed, 31 May 2017 15:21:34 +0000 (UTC) X-ZohoMail-DKIM: fail (Header signature does not verify) X-ZohoMail: RDKM_2 RSF_0 Z_629925259 SPT_0 From: Claudio Andr=C3=A9 It is possible to test libvirt using other distros in Travis via Docker; including (but not limited to) Fedora and Ubuntu. --- See it in action at https://travis-ci.org/claudioandre/libvirt/builds/23768= 7907=20 .travis.yml | 23 ++++++++++-------- tests/travis-ci.sh | 70 ++++++++++++++++++++++++++++++++++++++++++++++++++= ++++ 2 files changed, 83 insertions(+), 10 deletions(-) create mode 100755 tests/travis-ci.sh diff --git a/.travis.yml b/.travis.yml index 5a3e765..3ed2093 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,8 +1,6 @@ sudo: false language: c dist: precise -compiler: - - gcc cache: ccache addons: apt: @@ -62,15 +60,14 @@ git: before_install: - if [ "$TRAVIS_OS_NAME" =3D=3D "osx" ]; then brew update && brew instal= l gnutls libgcrypt yajl gettext rpcgen ; fi =20 -# the custom PATH is just to pick up OS-X homebrew & its harmless on Linux -before_script: - - PATH=3D"/usr/local/opt/gettext/bin:/usr/local/opt/rpcgen/bin:$PATH" ./= autogen.sh script: - - VIR_TEST_DEBUG=3D1 make -j3 && make -j3 syntax-check && make -j3 check + - tests/travis-ci.sh =20 # Environments here are run in addition to the main environment defined ab= ove matrix: include: + - compiler: gcc + dist: precise - compiler: clang dist: precise - compiler: clang @@ -79,10 +76,16 @@ matrix: dist: trusty - compiler: clang os: osx - script: - # many unit tests fail & so does syntax-check, so skip for now - # one day we must fix it though.... - - make -j3 + - services: docker + env: IMAGE=3Dubuntu:17.04 CCO=3Dgcc + dist: trusty + - services: docker + env: IMAGE=3Dubuntu:17.04 CCO=3Dclang + dist: trusty + + allow_failures: + - env: IMAGE=3Dubuntu:17.04 CCO=3Dgcc + - env: IMAGE=3Dubuntu:17.04 CCO=3Dclang =20 after_failure: - echo '=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D' diff --git a/tests/travis-ci.sh b/tests/travis-ci.sh new file mode 100755 index 0000000..07ec85d --- /dev/null +++ b/tests/travis-ci.sh @@ -0,0 +1,70 @@ +#!/bin/bash -e + +function do_Install_Dependencies(){ + echo + echo '-- Installing Dependencies --' + + apt-get update -qq + apt-get -y -qq install \ + build-essential git clang autoconf libtool libcmpicppimpl0 get= text \ + xsltproc autopoint libxml2-dev libncurses5-dev libreadline-dev= \ + zlib1g-dev libgnutls28-dev libgcrypt11-dev libavahi-client-dev= libsasl2-dev \ + libxen-dev lvm2 libgcrypt11-dev libparted0-dev libdevmapper-de= v uuid-dev \ + libudev-dev libpciaccess-dev libcap-ng-dev libnl-3-dev libnl-r= oute-3-dev \ + libyajl-dev libpcap0.8-dev libnuma-dev libnetcf-dev libaudit-d= ev \ + libxml2-utils libapparmor-dev dnsmasq-base librbd-dev w3c-mark= up-validator kmod > /dev/null +} + + +function do_Show_Info(){ + echo + echo '-- Environment --' + echo "Running on Docker: $DISTRO" + id + uname -a +} + + +function do_Show_Compiler(){ + + if [[ -n $CC ]]; then + echo + echo '-- Compiler in use --' + "$CC" --version + fi +} + + +# ----------- Build and Test libvirt ----------- + +if [[ -n $IMAGE ]]; then + # Run docker using the selected image; then build and test + docker run --privileged --cap-add=3DALL -v /lib/modules:/lib/modules \ + -v "$(pwd)":/cwd -e CC=3D$CCO -e DISTRO=3D$IMAGE "$IMAGE" sh -e -c "= \ + cd /cwd; \ + tests/travis-ci.sh" + exit $? +fi + +if [[ -n $DISTRO ]]; then + do_Show_Info + do_Install_Dependencies + do_Show_Compiler +fi + +echo -en 'travis_fold:start:autogen\r' + echo '-- Running ./autogen.sh --' + # The custom PATH is just to pick up OS-X homebrew & its harmless on L= inux + PATH=3D"/usr/local/opt/gettext/bin:/usr/local/opt/rpcgen/bin:$PATH" ./= autogen.sh +echo -en 'travis_fold:end:autogen\r' + +# Build and test +if [[ "$TRAVIS_OS_NAME" =3D "osx" ]]; then + # many unit tests fail & so does syntax-check, so skip for now + # one day we must fix it though.... + make -j3 +else + VIR_TEST_DEBUG=3D1 make -j3 && make -j3 syntax-check && make -j3 check +fi + +exit $? --=20 2.11.0 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list