Merge pull request #2966 from dbatwa/bug-fixes

VCloud Director - Bug fixes
This commit is contained in:
Wesley Beary 2014-06-03 14:04:50 -05:00
commit edc73c1334
3 changed files with 5 additions and 4 deletions

View File

@ -30,9 +30,9 @@ module Fog
attrs = { attrs = {
:xmlns => 'http://www.vmware.com/vcloud/v1.5' :xmlns => 'http://www.vmware.com/vcloud/v1.5'
} }
attr[:deploymentLeaseSeconds] = options[:deploymentLeaseSeconds] if options.key?(:deploymentLeaseSeconds) attrs[:deploymentLeaseSeconds] = options[:deploymentLeaseSeconds] if options.key?(:deploymentLeaseSeconds)
attr[:forceCustomization] = options[:forceCustomization] if options.key?(:forceCustomization) attrs[:forceCustomization] = options[:forceCustomization] if options.key?(:forceCustomization)
attr[:powerOn] = options[:powerOn] if options.key?(:powerOn) attrs[:powerOn] = options[:powerOn] if options.key?(:powerOn)
DeployVAppParams(attrs) DeployVAppParams(attrs)
end.to_xml end.to_xml

View File

@ -34,7 +34,7 @@ module Fog
request( request(
:body => body, :body => body,
:expects => 201, :expects => 201,
:headers => {'Content-Type' => 'application/vnd.vmware.vcloud.vAppTemplateParams+xml'}, :headers => {'Content-Type' => 'application/vnd.vmware.vcloud.uploadVAppTemplateParams+xml'},
:method => 'POST', :method => 'POST',
:parser => Fog::ToHashDocument.new, :parser => Fog::ToHashDocument.new,
:path => "vdc/#{vdc_id}/action/uploadVAppTemplate" :path => "vdc/#{vdc_id}/action/uploadVAppTemplate"

View File

@ -7,6 +7,7 @@
<vmext:VimObjectType>RESOURCE_POOL</vmext:VimObjectType> <vmext:VimObjectType>RESOURCE_POOL</vmext:VimObjectType>
</vmext:VimObjectRef> </vmext:VimObjectRef>
</VCloudExtension> </VCloudExtension>
<Link rel="add" type="application/vnd.vmware.vcloud.uploadVAppTemplateParams+xml" href="https://vcloud.example.com/api/vdc/1/action/uploadVAppTemplate" />
<Link rel="up" type="application/vnd.vmware.vcloud.org+xml" href="https://vcloud.example.com/api/org/1"/> <Link rel="up" type="application/vnd.vmware.vcloud.org+xml" href="https://vcloud.example.com/api/org/1"/>
<Link rel="add" type="application/vnd.vmware.vcloud.uploadVAppTemplateParams+xml" href="https://vcloud.example.com/api/vdc/1/action/uploadVAppTemplate"/> <Link rel="add" type="application/vnd.vmware.vcloud.uploadVAppTemplateParams+xml" href="https://vcloud.example.com/api/vdc/1/action/uploadVAppTemplate"/>
<Link rel="add" type="application/vnd.vmware.vcloud.media+xml" href="https://vcloud.example.com/api/vdc/1/media"/> <Link rel="add" type="application/vnd.vmware.vcloud.media+xml" href="https://vcloud.example.com/api/vdc/1/media"/>