]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
ceph-daemon: several commands that can infer fsids still require them
authorSage Weil <sage@redhat.com>
Thu, 21 Nov 2019 22:48:30 +0000 (16:48 -0600)
committerSage Weil <sage@redhat.com>
Fri, 22 Nov 2019 13:44:56 +0000 (07:44 -0600)
Signed-off-by: Sage Weil <sage@redhat.com>
src/ceph-daemon/ceph-daemon

index f9e27179a322deb9fdee0df07019eeaeaf0bbfa1..480ce55762aa4b2af3a357874017ca00847522bb 100755 (executable)
@@ -1330,6 +1330,8 @@ def command_shell():
 @infer_fsid
 def command_enter():
     # type: () -> int
+    if not args.fsid:
+        raise RuntimeError('must pass --fsid to specify cluster')
     (daemon_type, daemon_id) = args.name.split('.', 1)
     container_args = [] # type: List[str]
     if args.command:
@@ -1393,6 +1395,8 @@ def command_ceph_volume():
 @infer_fsid
 def command_unit():
     # type: () -> None
+    if not args.fsid:
+        raise RuntimeError('must pass --fsid to specify cluster')
     (daemon_type, daemon_id) = args.name.split('.', 1)
     unit_name = get_unit_name(args.fsid, daemon_type, daemon_id)
     call_throws([
@@ -1405,6 +1409,8 @@ def command_unit():
 @infer_fsid
 def command_logs():
     # type: () -> None
+    if not args.fsid:
+        raise RuntimeError('must pass --fsid to specify cluster')
     cmd = [container_path, 'logs']
     if args.follow:
         cmd.append('-f')