Export extractExTags and updateExclTags
[ganeti-local] / lib / client / gnt_cluster.py
index bd61469..408fde7 100644 (file)
@@ -373,6 +373,7 @@ def ShowClusterVersion(opts, args):
   ToStdout("Configuration format: %s", result["config_version"])
   ToStdout("OS api version: %s", result["os_api_version"])
   ToStdout("Export interface: %s", result["export_version"])
+  ToStdout("VCS version: %s", result["vcs_version"])
   return 0
 
 
@@ -521,6 +522,8 @@ def ClusterCopyFile(opts, args):
 
   """
   filename = args[0]
+  filename = os.path.abspath(filename)
+
   if not os.path.exists(filename):
     raise errors.OpPrereqError("No such filename '%s'" % filename,
                                errors.ECODE_INVAL)
@@ -995,7 +998,9 @@ def SetClusterParams(opts, args):
           opts.ipolicy_std_specs is not None or
           opts.ipolicy_disk_templates is not None or
           opts.ipolicy_vcpu_ratio is not None or
-          opts.ipolicy_spindle_ratio is not None):
+          opts.ipolicy_spindle_ratio is not None or
+          opts.modify_etc_hosts is not None or
+          opts.file_storage_dir is not None):
     ToStderr("Please give at least one of the parameters.")
     return 1
 
@@ -1105,6 +1110,7 @@ def SetClusterParams(opts, args):
     ipolicy=ipolicy,
     candidate_pool_size=opts.candidate_pool_size,
     maintain_node_health=mnh,
+    modify_etc_hosts=opts.modify_etc_hosts,
     uid_pool=uid_pool,
     add_uids=add_uids,
     remove_uids=remove_uids,
@@ -1118,6 +1124,7 @@ def SetClusterParams(opts, args):
     disk_state=disk_state,
     enabled_disk_templates=enabled_disk_templates,
     force=opts.force,
+    file_storage_dir=opts.file_storage_dir,
     )
   SubmitOrSend(op, opts)
   return 0
@@ -1623,7 +1630,8 @@ commands = {
      RESERVED_LVS_OPT, DRY_RUN_OPT, PRIORITY_OPT, PREALLOC_WIPE_DISKS_OPT,
      NODE_PARAMS_OPT, USE_EXTERNAL_MIP_SCRIPT, DISK_PARAMS_OPT, HV_STATE_OPT,
      DISK_STATE_OPT] + SUBMIT_OPTS +
-    [ENABLED_DISK_TEMPLATES_OPT, IPOLICY_STD_SPECS_OPT] + INSTANCE_POLICY_OPTS,
+     [ENABLED_DISK_TEMPLATES_OPT, IPOLICY_STD_SPECS_OPT, MODIFY_ETCHOSTS_OPT] +
+     INSTANCE_POLICY_OPTS + [GLOBAL_FILEDIR_OPT],
     "[opts...]",
     "Alters the parameters of the cluster"),
   "renew-crypto": (