From nobody Thu May 15 12:15:57 2025 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.zohomail.com; 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 1508227705142908.6452438135128; Tue, 17 Oct 2017 01:08:25 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 36879C047B63; Tue, 17 Oct 2017 08:08:23 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 8E90660603; Tue, 17 Oct 2017 08:08:22 +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 3DA883FAED; Tue, 17 Oct 2017 08:08:20 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v9H87GIq003234 for ; Tue, 17 Oct 2017 04:07:16 -0400 Received: by smtp.corp.redhat.com (Postfix) id 0C7525D974; Tue, 17 Oct 2017 08:07:16 +0000 (UTC) Received: from inaba.usersys.redhat.com (unknown [10.43.2.219]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 86B9E5D973 for ; Tue, 17 Oct 2017 08:07:12 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 36879C047B63 Authentication-Results: ext-mx07.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx07.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=libvir-list-bounces@redhat.com From: Andrea Bolognani To: libvir-list@redhat.com Date: Tue, 17 Oct 2017 10:07:08 +0200 Message-Id: <20171017080708.31635-1-abologna@redhat.com> In-Reply-To: <20171016160208.20112-1-abologna@redhat.com> References: <20171016160208.20112-1-abologna@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-loop: libvir-list@redhat.com Subject: [libvirt] [libvirt-jenkins-ci PATCH 6/5] fixup: Allow 'manage ACTION all' 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: , MIME-Version: 1.0 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.13 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.31]); Tue, 17 Oct 2017 08:08:24 +0000 (UTC) X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" When running the manage tool as part of scheduled maintainance, eg. in a cron job, it would be annoying to have to loop over the output of 'manage list' and call 'manage update' on each of the guests; it would also mean not taking advantage of Ansible's parallel execution capabilities, which can speed up things considerably. Solve the problem by allowing 'all' to be used as a guest name. Signed-off-by: Andrea Bolognani --- This will not be its own separate commit when pushing, but it will be squashed into commit 2/5, with a small adjustment required in commit 3/5 to deal with merge conflicts in the help text. guests/manage | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/guests/manage b/guests/manage index d84b8b0..5927d62 100755 --- a/guests/manage +++ b/guests/manage @@ -50,11 +50,11 @@ do_help() { Usage: $PROGRAM_NAME ACTION [OPTIONS] =20 Actions: - list List known guests - install GUEST Install GUEST - prepare GUEST Prepare or update GUEST. Can be run as many times as ne= eded - update GUEST Alias for prepare - help Display this help" + list List known guests + install GUEST Install GUEST + prepare GUEST|all Prepare or update GUEST. Can be run multiple times + update GUEST|all Alias for prepare + help Display this help" } =20 do_list() { @@ -113,9 +113,9 @@ do_prepare() { GUEST=3D"$1" =20 test "$GUEST" || { - die "Usage: $PROGRAM_NAME prepare GUEST" + die "Usage: $PROGRAM_NAME prepare GUEST|all" } - do_list | grep -q "$GUEST" || { + do_list | grep -q "$GUEST" || test "$GUEST" =3D all || { die "$PROGRAM_NAME: $GUEST: Unknown guest" } =20 --=20 2.13.6 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list