Skip to content

Commit

Permalink
Pass resource group as a string to power operation methods
Browse files Browse the repository at this point in the history
Fixes BZ #1509275
  • Loading branch information
Julian Cheal committed Nov 6, 2017
1 parent 7f2c2d9 commit 738caf1
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ module ManageIQ::Providers::Azure::CloudManager::Vm::Operations::Power
end

def raw_suspend
provider_service.stop(name, resource_group)
provider_service.stop(name, resource_group.name)
update_attributes!(:raw_power_state => "VM stopping")
end

Expand All @@ -20,22 +20,22 @@ def validate_pause
end

def raw_start
provider_service.start(name, resource_group)
provider_service.start(name, resource_group.name)
update_attributes!(:raw_power_state => "VM starting")
end

def raw_stop
provider_service.deallocate(name, resource_group)
provider_service.deallocate(name, resource_group.name)
update_attributes!(:raw_power_state => "VM deallocating")
end

def raw_restart
provider_service.restart(name, resource_group)
provider_service.restart(name, resource_group.name)
update_attributes!(:raw_power_state => "VM starting")
end

def reboot_guest
provider_service.restart(name, resource_group)
provider_service.restart(name, resource_group.name)
update_attributes!(:raw_power_state => "VM starting")
end
end

0 comments on commit 738caf1

Please sign in to comment.