]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
mgr/cephadm: leverage service specs
authorJoshua Schmid <jschmid@suse.de>
Wed, 26 Feb 2020 13:26:42 +0000 (14:26 +0100)
committerSage Weil <sage@redhat.com>
Sun, 1 Mar 2020 14:10:54 +0000 (08:10 -0600)
commit09ad4d39f40bbb7fb363d54c3bed4582332565d1
tree1895e097da3796de23504e951d542c45d8cddb95
parentfaadaa3155f61bcd5b9dedeebf1c5261062477d9
mgr/cephadm: leverage service specs

Fixes: https://tracker.ceph.com/issues/44205
This does a couple of things:

* Change the way apply_$service() works:

Instead of triggering the deployment mechanism it will rather
transform the already passed ServiceSpec into a json representation
and save it in a persistent mon_store section.

`mgr/cephadm/service_spec/$service|daemon_type/service_name`

These locations will be periodically checked in the serve() thread.
This works since all the apply_$service_type functions are idempotent.

* Allow to save a config-like specification in the mon_store.

`ceph orch apply -i <service_spec_file.yaml>`

will read the specified services and save them in the mon store
section like mentioned above. The same serve() mechanism like above
also applies to deployment.

Signed-off-by: Joshua Schmid <jschmid@suse.de>
src/pybind/mgr/cephadm/module.py
src/pybind/mgr/cephadm/tests/test_cephadm.py
src/pybind/mgr/mgr_module.py
src/pybind/mgr/orchestrator/_interface.py
src/pybind/mgr/orchestrator/module.py
src/pybind/mgr/tests/test_orchestrator.py