lib/cloudstack-cli/option_resolver.rb in cloudstack-cli-1.2.3 vs lib/cloudstack-cli/option_resolver.rb in cloudstack-cli-1.2.4
- old
+ new
@@ -6,10 +6,11 @@
resolve_project
resolve_compute_offering
resolve_template
resolve_disk_offering
resolve_iso
+ options[:size] = options[:disk_size] if options[:disk_size]
unless options[:template_id]
say "Error: Template or ISO is required.", :red
exit 1
end
resolve_networks
@@ -104,10 +105,11 @@
project_id: options[:project_id]
).first
say "Error: Iso '#{options[:iso]}' is invalid.", :red
exit 1
end
- unless options[:diskoffering_id]
+ unless options[:disk_offering_id]
+ puts options
say "Error: a disk offering is required when using iso.", :red
exit 1
end
options[:template_id] = iso['id']
options['hypervisor'] = (options[:hypervisor] || 'vmware')