Skip to content

Commit

Permalink
Merge pull request ManageIQ#112 from sseago/bz1494442
Browse files Browse the repository at this point in the history
bug 1494442: fix attach/detach disks automate methods
(cherry picked from commit 315fdb38b2ee923e3e79e08014ecf2f388b827df)

https://bugzilla.redhat.com/show_bug.cgi?id=1556814
  • Loading branch information
tzumainn authored and simaishi committed Apr 10, 2018
1 parent b98e2d1 commit 2e541df
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions app/models/manageiq/providers/openstack/cloud_manager.rb
Original file line number Diff line number Diff line change
Expand Up @@ -340,13 +340,13 @@ def vm_delete_evm_snapshot(vm, image_id)
raise
end

def vm_attach_volume(vm, volume_id, device = nil)
volume = find_by_id_filtered(CloudVolume, volume_id)
volume.raw_attach_volume(vm.ems_ref, device)
def vm_attach_volume(vm, options)
volume = CloudVolume.find_by(:id => options[:volume_id])
volume.raw_attach_volume(vm.ems_ref, options[:device])
end

def vm_detach_volume(vm, volume_id)
volume = find_by_id_filtered(CloudVolume, volume_id)
def vm_detach_volume(vm, options)
volume = CloudVolume.find_by(:id => options[:volume_id])
volume.raw_detach_volume(vm.ems_ref)
end

Expand Down

0 comments on commit 2e541df

Please sign in to comment.