From: Sage Weil Date: Fri, 4 Oct 2019 17:39:16 +0000 (-0500) Subject: ceph-daemon: add --output-pub-ssh-key for bootstrap X-Git-Tag: v15.1.0~1313^2~12 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=da2cd8aca2eb0327c0fd126b4535d6de3aefd563;p=ceph.git ceph-daemon: add --output-pub-ssh-key for bootstrap Signed-off-by: Sage Weil --- diff --git a/src/ceph-daemon b/src/ceph-daemon index 528d61380b15..b9b3504e2a5b 100755 --- a/src/ceph-daemon +++ b/src/ceph-daemon @@ -662,6 +662,11 @@ def command_bootstrap(): tmp_pub.write(ssh_pub) tmp_pub.flush() + if args.output_pub_ssh_key: + with open(args.output_put_ssh_key, 'w') as f: + f.write(ssh_pub) + logging.info('Wrote public SSH key to to %s' % args.output_pub_ssh_key) + CephContainer( image=args.image, entrypoint='/usr/bin/ceph', @@ -1215,6 +1220,9 @@ parser_bootstrap.add_argument( parser_bootstrap.add_argument( '--output-config', help='location to write conf file to connect to new cluster') +parser_bootstrap.add_argument( + '--output-pub-ssh-key', + help='location to write the cluster\'s public SSH key') parser_bootstrap.add_argument( '--skip-ssh', action='store_true',