]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
cephadm: move monitoring daemon args out of _get_daemon_args
authorJohn Mulligan <jmulligan@redhat.com>
Fri, 20 Oct 2023 15:13:52 +0000 (11:13 -0400)
committerJohn Mulligan <jmulligan@redhat.com>
Sat, 4 Nov 2023 18:53:07 +0000 (14:53 -0400)
Signed-off-by: John Mulligan <jmulligan@redhat.com>
src/cephadm/cephadm.py

index 3c95123046f9947e41fc330bceba9183bf279572..2c3e325c0a5831a4aeacb17b58f3f4445e600a49 100755 (executable)
@@ -2325,9 +2325,6 @@ def _get_daemon_args(ctx: CephadmContext, ident: 'DaemonIdentity') -> List[str]:
     if Ceph.for_daemon_type(daemon_type) or OSD.for_daemon_type(daemon_type):
         daemon = Ceph.create(ctx, ident)
         r += daemon.get_daemon_args()
-    elif daemon_type in Monitoring.components:
-        monitoring = Monitoring.create(ctx, ident)
-        r += monitoring.get_daemon_args()
 
     return r
 
@@ -2781,6 +2778,8 @@ def get_container(
             # '--path.rootfs=/rootfs' for node-exporter we need to disable selinux separation
             # between the node-exporter container and the host to avoid selinux denials
             container_args.extend(['--security-opt', 'label=disable'])
+        monitoring = Monitoring.create(ctx, ident)
+        d_args.extend(monitoring.get_daemon_args())
     elif daemon_type in Tracing.components:
         entrypoint = ''
         name = ident.daemon_name