diff options
author | Pavel Moravec <pmoravec@redhat.com> | 2019-11-13 16:51:33 +0100 |
---|---|---|
committer | Jake Hunsaker <jhunsake@redhat.com> | 2019-11-14 12:52:24 -0500 |
commit | 8d5c98732bac79253f906690c612083224551b92 (patch) | |
tree | c82def7d1ff47622ab8bbd688c27de1c3bd7e417 | |
parent | c63f6dda051501beef1f87053b545097d4945d39 (diff) | |
download | sos-8d5c98732bac79253f906690c612083224551b92.tar.gz |
[openstack_keystone] implement exec_cmd API change
Since e8bb94c, exec_cmd returns a dict instead of command output.
Reflect the change in testing the return value and using the output.
Resolves: #1860
Signed-off-by: Pavel Moravec <pmoravec@redhat.com>
Signed-off-by: Jake Hunsaker <jhunsake@redhat.com>
-rw-r--r-- | sos/plugins/openstack_keystone.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sos/plugins/openstack_keystone.py b/sos/plugins/openstack_keystone.py index 51486a55..943a6529 100644 --- a/sos/plugins/openstack_keystone.py +++ b/sos/plugins/openstack_keystone.py @@ -48,10 +48,11 @@ class OpenStackKeystone(Plugin): # collect domain config directory, if specified # if not, collect default /etc/keystone/domains - self.domain_config_dir = self.exec_cmd( + exec_out = self.exec_cmd( "crudini --get /etc/keystone/keystone.conf " "identity domain_config_dir") - if self.domain_config_dir is None or \ + self.domain_config_dir = exec_out['output'] + if exec_out['status'] != 0 or \ not(os.path.isdir(self.domain_config_dir)): self.domain_config_dir = "/etc/keystone/domains" self.add_copy_spec(self.domain_config_dir) |