clc-chef-metal-vsphere 0.3.33 → 0.3.34
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b75f04e739aacacdf87a879121fb781da3d7490d
|
4
|
+
data.tar.gz: 546c36a81fb1f1b9184db92c0a240ea7d7027a81
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 5f198c590723cfd2a735d8754a51542fa94506e25adc1bcbcbdad85a2acd95e53b600fd1622d5693391602b60cd6cbd454c71670f599a44c33bff5cea8c93dab
|
7
|
+
data.tar.gz: 8e0f36370103e28d8b83203eb8deb31883e5e0ef3980dcf4f0997b80b75aacfd44fd18d7504db15a059149ce46646d4a989bf6d5308c9def7f3cffb179d07770
|
@@ -236,13 +236,15 @@ module ChefMetalVsphere
|
|
236
236
|
now = Time.now.utc
|
237
237
|
trimmed_name = machine_spec.name.byteslice(0,15)
|
238
238
|
expected_name="#{trimmed_name}.#{domain}"
|
239
|
-
action_handler.report_progress "waiting to domain join and be named expected_name"
|
239
|
+
action_handler.report_progress "waiting to domain join and be named #{expected_name}"
|
240
240
|
until (Time.now.utc - now) > 30 || (vm.guest.hostName == expected_name) do
|
241
241
|
print "."
|
242
242
|
sleep 5
|
243
243
|
end
|
244
244
|
end
|
245
245
|
|
246
|
+
add_extra_nic(action_handler, vm_template_for(bootstrap_options), bootstrap_options, vm)
|
247
|
+
|
246
248
|
begin
|
247
249
|
wait_for_transport(action_handler, machine_spec, machine_options, vm)
|
248
250
|
rescue Timeout::Error
|
@@ -263,8 +265,6 @@ module ChefMetalVsphere
|
|
263
265
|
setup_ubuntu_dns(machine, bootstrap_options, machine_spec)
|
264
266
|
end
|
265
267
|
|
266
|
-
add_extra_nic(action_handler, vm_template_for(bootstrap_options), bootstrap_options, vm)
|
267
|
-
|
268
268
|
machine
|
269
269
|
end
|
270
270
|
|
@@ -462,8 +462,6 @@ module ChefMetalVsphere
|
|
462
462
|
if action_handler.should_perform_actions
|
463
463
|
action_handler.report_progress "waiting for #{machine_spec.name} (#{vm.config.instanceUuid} on #{driver_url}) to be connectable (transport up and running) ..."
|
464
464
|
|
465
|
-
_self = self
|
466
|
-
|
467
465
|
until remaining_wait_time(machine_spec, machine_options) < 0 || transport.available? do
|
468
466
|
print "."
|
469
467
|
sleep 5
|
@@ -158,9 +158,16 @@ module ChefMetalVsphere
|
|
158
158
|
|
159
159
|
def add_extra_nic(action_handler, vm_template, options, vm)
|
160
160
|
deviceAdditions, changes = network_device_changes(action_handler, vm_template, options)
|
161
|
+
|
161
162
|
if deviceAdditions.count > 0
|
162
|
-
|
163
|
-
|
163
|
+
current_networks = find_ethernet_cards_for(vm).map{|card| card.backing.deviceName}
|
164
|
+
new_devices = deviceAdditions.select { |device| !current_networks.include?(device.device.backing.deviceName)}
|
165
|
+
|
166
|
+
if new_devices.count > 0
|
167
|
+
action_handler.report_progress "Adding extra NICs"
|
168
|
+
task = vm.ReconfigVM_Task(:spec => RbVmomi::VIM.VirtualMachineConfigSpec(:deviceChange => new_devices))
|
169
|
+
task.wait_for_completion
|
170
|
+
end
|
164
171
|
end
|
165
172
|
end
|
166
173
|
|