From c615bcd75e85a2a2231d9944caeffd746e881e5e Mon Sep 17 00:00:00 2001 From: npraveen35 Date: Sun, 4 Feb 2018 00:08:02 -0800 Subject: [PATCH] Display private flavors in server list Update the code so that "openstack server list --all" also displays the names of private flavors. Change-Id: I4804fcd905eaf67b1ad9b461084eaf0caa820d2f Closes-Bug: #1742453 --- openstackclient/compute/v2/server.py | 2 +- releasenotes/notes/bug-1742453-ae4be6de90a3ae1d.yaml | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 releasenotes/notes/bug-1742453-ae4be6de90a3ae1d.yaml diff --git a/openstackclient/compute/v2/server.py b/openstackclient/compute/v2/server.py index c08f5caea1..f40fbdf6bf 100644 --- a/openstackclient/compute/v2/server.py +++ b/openstackclient/compute/v2/server.py @@ -1162,7 +1162,7 @@ class ListServer(command.Lister): # "Flavor Name" is not crucial, so we swallow any exceptions. if not parsed_args.no_name_lookup: try: - flavors_list = compute_client.flavors.list() + flavors_list = compute_client.flavors.list(is_public=None) for i in flavors_list: flavors[i.id] = i except Exception: diff --git a/releasenotes/notes/bug-1742453-ae4be6de90a3ae1d.yaml b/releasenotes/notes/bug-1742453-ae4be6de90a3ae1d.yaml new file mode 100644 index 0000000000..6103e3bf62 --- /dev/null +++ b/releasenotes/notes/bug-1742453-ae4be6de90a3ae1d.yaml @@ -0,0 +1,6 @@ +--- +fixes: + - | + The ``server list --all`` command now resolves non-public flavor names, + too, so that the ``Flavor`` column will be properly populated. + [Bug `1742453 `_]