summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenoît Knecht <benoit.knecht@fsfe.org>2013-09-23 15:58:42 +0200
committerSage Weil <sage@inktank.com>2013-09-26 16:20:58 -0700
commitb475ff9576f145d31c053213c699e13df76d2bcb (patch)
tree1cfbafcd56e74e12469b816bf4e455ecf827dae9
parent94548b4b67cca37366c7d8719209a6d2e7956811 (diff)
downloadceph-b475ff9576f145d31c053213c699e13df76d2bcb.tar.gz
Add CEPH_ARGS at the end of sys.argv
This allows, for instance, to pass a different client name to ceph by exporting CEPH_ARGS="--id client_id". Signed-off-by: Benoît Knecht <benoit.knecht@fsfe.org> Signed-off-by: Sage Weil <sage@inktank.com> (cherry picked from commit 30abe3244c86cbbe1f5b005850c29c9c0eafcad4)
-rwxr-xr-xsrc/ceph.in3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/ceph.in b/src/ceph.in
index b14842a6884..547a090e137 100755
--- a/src/ceph.in
+++ b/src/ceph.in
@@ -475,6 +475,9 @@ def complete(sigdict, args, target):
###
def main():
+ ceph_args = os.environ.get('CEPH_ARGS')
+ if ceph_args:
+ sys.argv.extend(ceph_args.split())
parser, parsed_args, childargs = parse_cmdargs()