fog-vsphere 3.6.3 → 3.6.4

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
  SHA256:
3
- metadata.gz: d7f02bc5a0e5ca64bdd9c0a91d563e500277b38244c98e2aaa2d745cea62ffd2
4
- data.tar.gz: 7b1c2379b72bcb4d19bfca8245b285868c9fc4e97ee866c6a62f9a7c9f8d1fe8
3
+ metadata.gz: 9c93f8cb4c51466540d02751656c83de747661c1a733ca27ebbdffde89f5c0dc
4
+ data.tar.gz: 54bc1daeb38c253cf87978cb6a51e5f7f8da70f84627b8e637da8af1e2dca3e7
5
5
  SHA512:
6
- metadata.gz: 641de456e8e02ae6ec49512b70278bfc0c9662a5a08337bad97fadf174f199272e09dd8f15d50decf0efbd1ca8e3be9a4ba38189151afe98b5f3159d95ddd5a1
7
- data.tar.gz: 700f2a33830fdf7c74c1eb4d637cc701a9d8d5ed8507983f8c24d24cb6e0b985f175207e68250761e3dc60496456467cc6dd4dad6256ec39c5f483f5dcebf6a2
6
+ metadata.gz: 06d063d385dd60f23e5e8dce2cc195722c6d2152ba6afe25cde593ebf954e102f2138e0ad3720c2a823c01dcea7b7d4a9ff488c266387a135c272381405addfa
7
+ data.tar.gz: f0dbfd50e8887a2aeee725791b188748e4bd14416d82d5b8af53d16fe12ea5cbb52e2041c85fa6511e284ecd544ba41db92ab7beb8ca45b0286b5cffd2565cee
@@ -135,6 +135,7 @@ module Fog
135
135
  request :host_shutdown
136
136
  request :host_start_maintenance
137
137
  request :host_finish_maintenance
138
+ request :get_vm_first_sata_controller
138
139
 
139
140
  module Shared
140
141
  attr_reader :vsphere_is_vcenter
@@ -252,7 +252,7 @@ module Fog
252
252
  operation: options[:operation],
253
253
  device: controller_class.new(key: options[:key] || (1000 + index),
254
254
  busNumber: options[:bus_id] || index,
255
- sharedBus: controller_get_shared_from_options(options))
255
+ **(options[:type] == RbVmomi::VIM::VirtualAHCIController ? {} : {sharedBus: controller_get_shared_from_options(options)}))
256
256
  }
257
257
  end
258
258
 
@@ -0,0 +1,21 @@
1
+ module Fog
2
+ module Vsphere
3
+ class Compute
4
+ class Real
5
+ def get_vm_first_sata_controller(vm_id)
6
+ ctrl = get_vm_ref(vm_id).config.hardware.device.find { |device| device.is_a?(RbVmomi::VIM::VirtualAHCIController) }
7
+ raise(Fog::Vsphere::Compute::NotFound) unless ctrl
8
+ {
9
+ type: ctrl&.class.to_s,
10
+ device_info: ctrl&.deviceInfo,
11
+ bus_number: ctrl&.busNumber,
12
+ key: ctrl&.key
13
+ }
14
+ end
15
+ end
16
+ class Mock
17
+ def get_vm_first_sata_controller(vm_id); end
18
+ end
19
+ end
20
+ end
21
+ end
@@ -20,7 +20,7 @@ module Fog
20
20
  device: RbVmomi::VIM::VirtualCdrom(
21
21
  backing: backing,
22
22
  key: cdrom_obj.key,
23
- controllerKey: cdrom_obj.controllerKey,
23
+ controllerKey: options['controller_key'] || cdrom_obj.controllerKey,
24
24
  connectable: RbVmomi::VIM::VirtualDeviceConnectInfo(
25
25
  startConnected: options['start_connected'] || false,
26
26
  connected: options['connected'] || false,
@@ -1,5 +1,5 @@
1
1
  module Fog
2
2
  module Vsphere
3
- VERSION = '3.6.3'.freeze
3
+ VERSION = '3.6.4'.freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fog-vsphere
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.6.3
4
+ version: 3.6.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - J.R. Garcia
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-01-16 00:00:00.000000000 Z
11
+ date: 2024-03-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: fog-core
@@ -297,6 +297,7 @@ files:
297
297
  - lib/fog/vsphere/requests/compute/get_storage_pod.rb
298
298
  - lib/fog/vsphere/requests/compute/get_template.rb
299
299
  - lib/fog/vsphere/requests/compute/get_virtual_machine.rb
300
+ - lib/fog/vsphere/requests/compute/get_vm_first_sata_controller.rb
300
301
  - lib/fog/vsphere/requests/compute/get_vm_first_scsi_controller.rb
301
302
  - lib/fog/vsphere/requests/compute/host_finish_maintenance.rb
302
303
  - lib/fog/vsphere/requests/compute/host_shutdown.rb