Commit 44c44832 authored by Iustin Pop's avatar Iustin Pop

Move the “--no-shutdown” option to cli.py

Signed-off-by: default avatarIustin Pop <iustin@google.com>
Reviewed-by: default avatarMichael Hanselmann <hansmi@google.com>
parent ee3f9578
......@@ -87,6 +87,7 @@ __all__ = [
"NONICS_OPT",
"NONLIVE_OPT",
"NONPLUS1_OPT",
"NOSHUTDOWN_OPT",
"NOSTART_OPT",
"NOSSH_KEYCHECK_OPT",
"NOVOTING_OPT",
......@@ -804,6 +805,11 @@ IGNORE_SECONDARIES_OPT = cli_option("--ignore-secondaries",
default=False, action="store_true",
help="Ignore errors from secondaries")
NOSHUTDOWN_OPT = cli_option("","--noshutdown", dest="shutdown",
action="store_false", default=True,
help="Don't shutdown the instance (unsafe)")
def _ParseArgs(argv, commands, aliases):
"""Parser for the command line arguments.
......
......@@ -233,10 +233,7 @@ commands = {
[DEBUG_OPT, NODE_LIST_OPT],
"", "Lists instance exports available in the ganeti cluster"),
'export': (ExportInstance, ARGS_ONE_INSTANCE,
[DEBUG_OPT, FORCE_OPT, SINGLE_NODE_OPT,
cli_option("","--noshutdown", dest="shutdown",
action="store_false", default=True,
help="Don't shutdown the instance (unsafe)"), ],
[DEBUG_OPT, FORCE_OPT, SINGLE_NODE_OPT, NOSHUTDOWN_OPT]
"-n <target_node> [opts...] <name>",
"Exports an instance to an image"),
'import': (ImportInstance, ARGS_ONE_INSTANCE, import_opts,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment