I think you are reading the error message backwards. Packer converts the value to a number, but the plugin (which is unknown to me) expects a string. I think this is probably a bug in the plugin.
On Jan 31, 2018 19:08, "Kevin Milner" <[email protected]> wrote: > Hello, > In my variables portion I want to be able to specify default values that > can be overridden for disk_size, CPUs, and RAM (this is for jetbrains' > vcenter builder plugin). In the builder section, I have this: > "disk_size": 100, > "CPUs": 4, > "RAM": 8000, > > and it works fine, but I want to be able to use variables in place. > However, if I put format as: > "disk_size": {{user `vm_disk_size`}}, > "CPUs": {{user `vm_cpu`}}, > "RAM": {{user `vm_ram`}}, > > (No quotations around the value), the parser chokes because it doesn't > know what to do with the brackets. I would expect this. > If I put the quotation marks around the values, however, I get the > following error: > * variable vm_cpu: '' expected type 'string', got unconvertible type > 'float64' > > So it seems like I need to be able to denote this variable as a non-string > type. Any idea how I do this? > Thanks > > -- > This mailing list is governed under the HashiCorp Community Guidelines - > https://www.hashicorp.com/community-guidelines.html. Behavior in > violation of those guidelines may result in your removal from this mailing > list. > > GitHub Issues: https://github.com/mitchellh/packer/issues > IRC: #packer-tool on Freenode > --- > You received this message because you are subscribed to the Google Groups > "Packer" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit https://groups.google.com/d/ > msgid/packer-tool/a0839d38-edea-4eed-be5f-f0b1ea614bee%40googlegroups.com > <https://groups.google.com/d/msgid/packer-tool/a0839d38-edea-4eed-be5f-f0b1ea614bee%40googlegroups.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- This mailing list is governed under the HashiCorp Community Guidelines - https://www.hashicorp.com/community-guidelines.html. Behavior in violation of those guidelines may result in your removal from this mailing list. GitHub Issues: https://github.com/mitchellh/packer/issues IRC: #packer-tool on Freenode --- You received this message because you are subscribed to the Google Groups "Packer" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/packer-tool/CALz9Rt86fi3MFRN3G%3Dkfrt2Fs%3D6BQGAZDZvShimhx1UkGS561g%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
