Fixed error caused by total_memory option whereby the wrong type was not changed to the right type for a calculation in the packerfile (string -> int)

This commit is contained in:
Jjk422
2017-04-18 23:13:07 +01:00
parent 004c740ccd
commit aba2e2b028

View File

@@ -6,7 +6,7 @@
<%= if (@options.has_key? :memory_per_vm)
"[ \"modifyvm\", \"{{.Name}}\", \"--memory\", \"#{@options[:memory_per_vm]}\" ],"
elsif (@options.has_key? :total_memory)
"[ \"modifyvm\", \"{{.Name}}\", \"--memory\", \"#{@options[:total_memory]/@systems.length}\" ],"
"[ \"modifyvm\", \"{{.Name}}\", \"--memory\", \"#{@options[:total_memory].to_i/@systems.length}\" ],"
end %>
<%= if (@options.has_key? :max_cpu_cores)
"[ \"modifyvm\", \"{{.Name}}\", \"--cpus\", \"#{@options[:max_cpu_cores]}\" ],"