+
+ # Get this nodes configuration
+ node = self.config.get_node(hostname)
+ # Which plc does this node talk to
+ plc = self.config.get_plc(node['plc'])
+ print node
+ api = plc.config.api
+ auth = plc.config.auth
+ host = node['host']
+ bootimage_filename = '%(hostname)s-bootcd.iso' % locals()
+ tmpdir = '/usr/tmp/'
+ homedir = node['homedir']
+ diskimage_path = "/%(homedir)s/%(hostname)s-hda.img" % locals()
+ bootimage_tmppath = "%(tmpdir)s/%(bootimage_filename)s" % locals()
+ bootimage_path = "%(homedir)s/%(bootimage_filename)s" % locals()
+ if host in ['localhost', None]:
+ remote_bootimage_path = bootimage_path
+ else:
+ remote_bootimage_path = "%(host)s:%(bootimage_path)s" % locals()
+
+ # wait up to 30 minutes for a node to boot and install itself correctly