1
0
mirror of https://github.com/OpenNebula/one.git synced 2025-03-23 22:50:09 +03:00

Bug #4431: Add datastore suffix to image name in vCenter image import

This commit is contained in:
Tino Vazquez 2016-05-23 19:05:13 +02:00
parent f8f83da64f
commit 01324189a6
2 changed files with 4 additions and 3 deletions

View File

@ -105,7 +105,8 @@ cmd=CommandParser::CmdParser.new(ARGV) do
oneimage create -d 1 --name ubuntu --path /tmp/ubuntu.qcow2 \\
--prefix sd --type OS --driver qcow2 \\
--description "A OS plain installation"
--description "A OS plain installation \\
--persistent"
- a datablock image of 400MB:

View File

@ -684,12 +684,12 @@ class VIClient
if !ipool["IMAGE[NAME=\"#{image_name}\"]"]
img_templates << {
:name => "#{image_name}",
:name => "#{image_name} - #{ds_name}",
:path => image_path,
:size => (image.fileSize / 1024).to_s,
:type => image.class.to_s,
:dsid => ds_id,
:one => "NAME=\"#{image_name}\"\n"\
:one => "NAME=\"#{image_name} - #{ds_name}\"\n"\
"PATH=\"vcenter://#{image_path}\"\n"\
"PERSISTENT=\"YES\"\n"\
}