mirror of
https://github.com/OpenNebula/one.git
synced 2025-03-30 22:50:10 +03:00
Feature #3471: Change the onedvc create command to accept a name
This commit is contained in:
parent
09a7409303
commit
f80025329d
@ -117,15 +117,10 @@ cmd=CommandParser::CmdParser.new(ARGV) do
|
||||
Creates a new VDC
|
||||
EOT
|
||||
|
||||
command :create, create_desc, :file do
|
||||
command :create, create_desc, :name do
|
||||
helper.create_resource(options) do |vdc|
|
||||
begin
|
||||
template = File.read(args[0])
|
||||
vdc.allocate(template)
|
||||
rescue => e
|
||||
STDERR.puts e.message
|
||||
exit -1
|
||||
end
|
||||
template = "NAME = \"#{args[0]}\""
|
||||
vdc.allocate(template)
|
||||
end
|
||||
end
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user