]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
cephadm: ensure entrypoint is assigned a string
authorJohn Mulligan <jmulligan@redhat.com>
Fri, 20 Oct 2023 14:30:16 +0000 (10:30 -0400)
committerJohn Mulligan <jmulligan@redhat.com>
Sat, 4 Nov 2023 18:53:06 +0000 (14:53 -0400)
Ensure that the entrypoint variable is assigned a string. The
custom container class can have None and that can confuse future
refactoring.
The mypy command we're using does not notice this.

Signed-off-by: John Mulligan <jmulligan@redhat.com>
src/cephadm/cephadm.py

index 9a36360bf2dc7e5f23e700a71f7eb358549a4a01..b47d12f92493f39a041989af734da5e7de73ccd3 100755 (executable)
@@ -2832,7 +2832,7 @@ def get_container(
         privileged = True
     elif daemon_type == CustomContainer.daemon_type:
         cc = CustomContainer.init(ctx, ident.fsid, ident.daemon_id)
-        entrypoint = cc.entrypoint
+        entrypoint = cc.entrypoint or ''
         host_network = False
         envs.extend(cc.get_container_envs())
         container_args.extend(cc.get_container_args())