Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Provisioning of disconnected VolumeTemplate #173

Merged
merged 1 commit into from
Dec 13, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,4 +1,13 @@
module ManageIQ::Providers::Openstack::CloudManager::Provision::Cloning
def find_destination_in_vmdb(ems_ref)
super
rescue NoMethodError => ex
# TODO: this should not be needed after we update refresh to not disconnect VmOrTemplate from EMS
_log.debug("Unable to find Provison Source ExtmanagementSystem: #{ex}")
_log.debug("Trying use attribute src_ems_id=#{options[:src_ems_id].try(:first)} instead.")
vm_model_class.find_by(:ems_id => options[:src_ems_id].try(:first), :ems_ref => ems_ref)
end

def do_clone_task_check(clone_task_ref)
connection_options = {:tenant_name => options[:cloud_tenant][1]} if options[:cloud_tenant].kind_of?(Array)
source.with_provider_connection(connection_options) do |openstack|
Expand Down