]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mgr/cephadm: include service_name is generated DaemonDescription
authorSage Weil <sage@newdream.net>
Fri, 23 Apr 2021 19:13:05 +0000 (15:13 -0400)
committerSage Weil <sage@newdream.net>
Wed, 19 May 2021 12:43:13 +0000 (08:43 -0400)
This makes 'orch ls' match up daemosn to services (and probably cleans up
other bits and pieces) when the old daemon id -> service name calc code
can't do its thing.

Signed-off-by: Sage Weil <sage@newdream.net>
src/pybind/mgr/cephadm/services/cephadmservice.py
src/pybind/mgr/cephadm/tests/test_cephadm.py

index 0ce23170b7774ee9355911292aef80f22ca87a6d..fee4820411b981fa2026a99e828244ddd737fa9e 100644 (file)
@@ -94,6 +94,7 @@ class CephadmDaemonDeploySpec:
         return DaemonDescription(
             daemon_type=self.daemon_type,
             daemon_id=self.daemon_id,
+            service_name=self.service_name,
             hostname=self.host,
             status=status,
             status_desc=status_desc,
index 3e333ac7bdd8692a2792aa9f0e2cedc1a6a89aee..adb07d878569c9f2d2a47551ea4274545546b5ad 100644 (file)
@@ -117,6 +117,7 @@ class TestCephadm(object):
 
                 assert [remove_id_events(dd) for dd in wait(cephadm_module, c)] == [
                     {
+                        'service_name': 'mds.name',
                         'daemon_type': 'mds',
                         'hostname': 'test',
                         'status': 1,