]> git.apps.os.sepia.ceph.com Git - ceph-ansible.git/commit
ceph_key: rework container support
authorSébastien Han <seb@redhat.com>
Fri, 16 Nov 2018 09:46:10 +0000 (10:46 +0100)
committermergify[bot] <mergify[bot]@users.noreply.github.com>
Tue, 27 Nov 2018 16:47:40 +0000 (16:47 +0000)
commitbc6e652a1c4eb8d456717cf3af130c45597084d0
treec94cb34bf88c9516ab577b826ea377259c09ee4e
parenta9b337ba660da641f36c79a92e0aace217175ff0
ceph_key: rework container support

Previously, we were doing a 'docker exec' inside a mon container, this
worked but this wasn't ideal since it required a mon to be up to
generate keys. We must be able to generate a key without a running mon,
e.g, when we create the initial key or simply when you want to generate
a key from any node that is not a mon.
Now, just like the ceph_volume module we use a 'docker run' command with
the right binary as an entrypoint to perform the choosen action, this is
more elegant and also only requires an env variable to be set in the
playbook: CEPH_CONTAINER_IMAGE.

Signed-off-by: Sébastien Han <seb@redhat.com>
library/ceph_key.py
library/test_ceph_key.py