initial code repo
[stor4nfv.git] / src / ceph / src / test / cli / ceph-authtool / cap-overwrite.t
diff --git a/src/ceph/src/test/cli/ceph-authtool/cap-overwrite.t b/src/ceph/src/test/cli/ceph-authtool/cap-overwrite.t
new file mode 100644 (file)
index 0000000..94146b2
--- /dev/null
@@ -0,0 +1,11 @@
+  $ ceph-authtool kring --create-keyring --gen-key
+  creating kring
+
+  $ ceph-authtool --cap osd 'allow rx pool=swimming' kring
+  $ ceph-authtool kring --list|grep -E '^[[:space:]]caps '
+  \tcaps osd = "allow rx pool=swimming" (esc)
+
+# TODO it seems --cap overwrites all previous caps; is this wanted?
+  $ ceph-authtool --cap mds 'allow' kring
+  $ ceph-authtool kring --list|grep -E '^[[:space:]]caps '
+  \tcaps mds = "allow" (esc)