]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
rest api: Set default ceph.conf and id options
authorWido den Hollander <wido@42on.com>
Mon, 26 Jun 2017 09:50:34 +0000 (11:50 +0200)
committerWido den Hollander <wido@42on.com>
Mon, 26 Jun 2017 09:50:34 +0000 (11:50 +0200)
This allows for easy execution of the REST API:

  $ /usr/bin/ceph-rest-api

Signed-off-by: Wido den Hollander <wido@42on.com>
src/ceph-rest-api

index 1405ab5bbae50e452e6dc9733fdb746404ce32e7..6864028d365a699c27b59dc072f05c8c758ff1d4 100755 (executable)
@@ -14,10 +14,11 @@ DEVMODEMSG = '*** DEVELOPER MODE: setting PYTHONPATH and LD_LIBRARY_PATH'
 
 def parse_args():
     parser = argparse.ArgumentParser(description="Ceph REST API webapp")
-    parser.add_argument('-c', '--conf', help='Ceph configuration file')
+    parser.add_argument('-c', '--conf', help='Ceph configuration file',
+                        default='/etc/ceph/ceph.conf')
     parser.add_argument('--cluster', help='Ceph cluster name')
     parser.add_argument('-n', '--name', help='Ceph client name')
-    parser.add_argument('-i', '--id', help='Ceph client id')
+    parser.add_argument('-i', '--id', help='Ceph client id', default='admin')
 
     return parser.parse_known_args()