Commit 4a25828c authored by Iustin Pop's avatar Iustin Pop
Browse files

Unify the “--file-storage-dir” option


Signed-off-by: default avatarIustin Pop <iustin@google.com>
Reviewed-by: default avatarGuido Trotter <ultrotter@google.com>
parent 26023ecd
......@@ -49,6 +49,7 @@ __all__ = [
"DEBUG_SIMERR_OPT",
"DISK_TEMPLATE_OPT",
"FIELDS_OPT",
"FILESTORE_DIR_OPT",
"FORCE_OPT",
"NOHDR_OPT",
"NONICS_OPT",
......@@ -487,6 +488,11 @@ NONICS_OPT = cli_option("--no-nics", default=False, action="store_true",
help="Do not create any network cards for"
" the instance")
FILESTORE_DIR_OPT = cli_option("--file-storage-dir", dest="file_storage_dir",
help="Relative path under default cluster-wide"
" file storage dir to store file-based disks",
default=None, metavar="<DIR>")
def _ParseArgs(argv, commands, aliases):
"""Parser for the command line arguments.
......
......@@ -245,10 +245,7 @@ import_opts = [
help="Select nodes for the instance automatically using the"
" <NAME> iallocator plugin", default=None, type="string",
completion_suggest=OPT_COMPL_ONE_IALLOCATOR),
cli_option("--file-storage-dir", dest="file_storage_dir",
help="Relative path under default cluster-wide file storage dir"
" to store file-based disks", default=None,
metavar="<DIR>"),
FILESTORE_DIR_OPT,
cli_option("--file-driver", dest="file_driver", help="Driver to use"
" for image files", default="loop", metavar="<DRIVER>",
choices=list(constants.FILE_DRIVER)),
......
......@@ -1396,10 +1396,7 @@ add_opts = [
cli_option("--no-ip-check", dest="ip_check", default=True,
action="store_false", help="Don't check that the instance's IP"
" is alive (only valid with --no-start)"),
cli_option("--file-storage-dir", dest="file_storage_dir",
help="Relative path under default cluster-wide file storage dir"
" to store file-based disks", default=None,
metavar="<DIR>"),
FILESTORE_DIR_OPT,
cli_option("--file-driver", dest="file_driver", help="Driver to use"
" for image files", default="loop", metavar="<DRIVER>",
choices=list(constants.FILE_DRIVER)),
......
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