initial code repo
[stor4nfv.git] / src / ceph / src / test / cli / ceph-conf / env-vs-args.t
diff --git a/src/ceph/src/test/cli/ceph-conf/env-vs-args.t b/src/ceph/src/test/cli/ceph-conf/env-vs-args.t
new file mode 100644 (file)
index 0000000..d14c483
--- /dev/null
@@ -0,0 +1,14 @@
+# we can use CEPH_CONF to override the normal configuration file location.
+  $ env CEPH_CONF=from-env ceph-conf -s foo bar
+  .* \-1 did not load config file, using default settings. (re)
+  .* \-1 Errors while parsing config file! (re)
+  .* \-1 parse_file: cannot open from-env: \(2\) No such file or directory (re)
+  .* \-1 Errors while parsing config file! (re)
+  .* \-1 parse_file: cannot open from-env: \(2\) No such file or directory (re)
+  [1]
+
+# command-line arguments should override environment
+  $ env -u CEPH_CONF ceph-conf -c from-args
+  global_init: unable to open config file from search list from-args
+  [1]
+