"FIELDS_OPT",
"FORCE_OPT",
"NOHDR_OPT",
+ "NWSYNC_OPT",
"SEP_OPT",
"SUBMIT_OPT",
"SYNC_OPT",
help="Debugging option that makes the operation"
" treat most runtime checks as failed")
+NWSYNC_OPT = cli_option("--no-wait-for-sync", dest="wait_for_sync",
+ default=True, action="store_false",
+ help="Don't wait for sync (DANGEROUS!)")
+
def _ParseArgs(argv, commands, aliases):
"""Parser for the command line arguments.
type="identkeyval"),
cli_option("--no-nics", default=False, action="store_true",
help="Do not create any network cards for the instance"),
- cli_option("--no-wait-for-sync", dest="wait_for_sync", default=True,
- action="store_false", help="Don't wait for sync (DANGEROUS!)"),
+ NWSYNC_OPT,
cli_option("--src-node", dest="src_node", help="Source node",
metavar="<node>",
completion_suggest=OPT_COMPL_ONE_NODE),
type="identkeyval"),
cli_option("--no-nics", default=False, action="store_true",
help="Do not create any network cards for the instance"),
- cli_option("--no-wait-for-sync", dest="wait_for_sync", default=True,
- action="store_false", help="Don't wait for sync (DANGEROUS!)"),
+ NWSYNC_OPT,
cli_option("--no-start", dest="start", default=True,
action="store_false", help="Don't start the instance after"
" creation"),
'grow-disk': (GrowDisk,
[ArgInstance(min=1, max=1), ArgUnknown(min=1, max=1),
ArgUnknown(min=1, max=1)],
- [DEBUG_OPT, SUBMIT_OPT,
- cli_option("--no-wait-for-sync",
- dest="wait_for_sync", default=True,
- action="store_false",
- help="Don't wait for sync (DANGEROUS!)"),
- ],
+ [DEBUG_OPT, SUBMIT_OPT, NWSYNC_OPT],
"<instance> <disk> <size>", "Grow an instance's disk"),
'list-tags': (ListTags, ARGS_ONE_INSTANCE, [DEBUG_OPT],
"<instance_name>", "List the tags of the given instance"),