Remove the HTS_COPY_VNC_PASSWORD constant/feature
authorGuido Trotter <ultrotter@google.com>
Wed, 13 May 2009 10:33:57 +0000 (11:33 +0100)
committerGuido Trotter <ultrotter@google.com>
Fri, 22 May 2009 10:01:49 +0000 (11:01 +0100)
Currently just for xen-hvm we copy the vnc password on node-add.  This
will be changed for 2.1 with a more advanced gnt-cluster redist-conf
functionality which is going to be used by node-add as well.

Signed-off-by: Guido Trotter <ultrotter@google.com>
Reviewed-by: Iustin Pop <iustin@google.com>

lib/cmdlib.py
lib/constants.py

index e2aec21..7c25d95 100644 (file)
@@ -2264,16 +2264,6 @@ class LUAddNode(LogicalUnit):
         if to_result.failed or not to_result.data:
           logging.error("Copy of file %s to node %s failed", fname, to_node)
 
-    to_copy = []
-    enabled_hypervisors = self.cfg.GetClusterInfo().enabled_hypervisors
-    if constants.HTS_COPY_VNC_PASSWORD.intersection(enabled_hypervisors):
-      to_copy.append(constants.VNC_PASSWORD_FILE)
-
-    for fname in to_copy:
-      result = self.rpc.call_upload_file([node], fname)
-      if result[node].failed or not result[node]:
-        logging.error("Could not copy file %s to node %s", fname, node)
-
     if self.op.readd:
       self.context.ReaddNode(new_node)
     else:
index 0bcf70a..1182cdf 100644 (file)
@@ -353,7 +353,6 @@ HT_XEN_HVM = "xen-hvm"
 HT_KVM = "kvm"
 HYPER_TYPES = frozenset([HT_XEN_PVM, HT_FAKE, HT_XEN_HVM, HT_KVM])
 HTS_REQ_PORT = frozenset([HT_XEN_HVM, HT_KVM])
-HTS_COPY_VNC_PASSWORD = frozenset([HT_XEN_HVM])
 
 VNC_BASE_PORT = 5900
 VNC_PASSWORD_FILE = _autoconf.SYSCONFDIR + "/ganeti/vnc-cluster-password"