From 294d90fe8dcde195a443b7cf90d4b715c867dcaf Mon Sep 17 00:00:00 2001 From: David Moreau Simard Date: Thu, 14 Jan 2021 13:29:31 -0500 Subject: [PATCH] cli: add missing controller arg to playbook metrics This provides the ability to get playbook metrics for a specific controller. Change-Id: I57abfc1bf6ef5e0ceb420da4f9a28094269a78ab --- ara/cli/playbook.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/ara/cli/playbook.py b/ara/cli/playbook.py index 23535d2e..2a835e3b 100644 --- a/ara/cli/playbook.py +++ b/ara/cli/playbook.py @@ -429,6 +429,12 @@ class PlaybookMetrics(Lister): default=None, help=("List playbooks matching the provided name (full or partial)"), ) + parser.add_argument( + "--controller", + metavar="", + default=None, + help=("List playbooks that ran from the provided controller (full or partial)"), + ) parser.add_argument( "--path", metavar="", @@ -486,6 +492,9 @@ class PlaybookMetrics(Lister): if args.name is not None: query["name"] = args.name + if args.controller is not None: + query["controller"] = args.controller + if args.path is not None: query["path"] = args.path