diff options
Diffstat (limited to 'clusterman/__main__.py')
| -rw-r--r-- | clusterman/__main__.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/clusterman/__main__.py b/clusterman/__main__.py index d22786b..be2ea22 100644 --- a/clusterman/__main__.py +++ b/clusterman/__main__.py @@ -20,6 +20,7 @@ def main(): node_cmd_list.add_argument("-g", "--group" ,help="Group to list") # Exec node_cmd_list=node_subparsers.add_parser("exec") + node_cmd_list.add_argument("-g", "--group" ,help="Group to run the command on") node_cmd_list.add_argument("cmd",help="Command to run",nargs=argparse.REMAINDER) ##### Frontend commands ##### @@ -58,7 +59,10 @@ def main(): else: node.ls() elif args.command == "exec": - node.exec(args.cmd) + if args.group: + node.exec(args.cmd,args.group) + else: + node.exec(args.cmd) else: target_node.print_help(sys.stderr) sys.exit(1) |
