From 14767e2909d4d16fada67093b49fa675fc96027f Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Tue, 25 Aug 2020 14:05:43 -0400 Subject: [PATCH] Fix nodedeploy -c --- confluent_client/bin/nodedeploy | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/confluent_client/bin/nodedeploy b/confluent_client/bin/nodedeploy index 02bd516d..4a675793 100755 --- a/confluent_client/bin/nodedeploy +++ b/confluent_client/bin/nodedeploy @@ -69,11 +69,14 @@ def main(args): ap.add_argument('-p', '--prepare', help='Configure for deployment without setting boot device or rebooting', action='store_true') ap.add_argument('-m', '--maxnodes', help='Specifiy a maximum nodes to be deployed') ap.add_argument('noderange', help='Set of nodes to deploy') - ap.add_argument('profile', help='Profile name to deploy') + ap.add_argument('profile', nargs='?', help='Profile name to deploy') args = ap.parse_args(args) - if not args.network and not args.prepare: + if not args.network and not args.prepare and not args.clear: sys.stderr.write('-n or -p is a required argument currently\n') return 1 + if not args.clear and args.profile is None: + sys.stderr.write(' is a required argument') + return 1 c = client.Command() c.stop_if_noderange_over(args.noderange, args.maxnodes) if args.clear: