]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ansible.git/commit
ceph_key: handle error in a better way
authorGuillaume Abrioux <gabrioux@redhat.com>
Mon, 7 Jun 2021 12:51:43 +0000 (14:51 +0200)
committerGuillaume Abrioux <gabrioux@redhat.com>
Mon, 14 Jun 2021 21:46:20 +0000 (23:46 +0200)
commitd58500ade01c7c4cc20b6bbaf8f5789d825b8d1b
tree798c0725c89cadb7634073f20297128f6d052982
parentf9a73149a4da79db4942d98b366d686665d402d7
ceph_key: handle error in a better way

When calling the `ceph_key` module with `state: info`, if the ceph
command called fails, the actual error is hidden by the module which
makes it pretty difficult to troubleshoot.

The current code always states that if rc is not equal to 0 the keyring
doesn't exist.

`state: info` should always return the actual rc, stdout and stderr.

Closes: https://bugzilla.redhat.com/show_bug.cgi?id=1964889
Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
library/ceph_key.py
roles/ceph-mon/tasks/deploy_monitors.yml