I am trying to work out the correct way to use variables as part of the 
json parameter for the chef-solo provisioner. I have the user variable 
called bar_enabled and I want to set it to true.

For example, I can pass this:

      "type" : "chef-solo",
      "json" : {
        "foo" : {
          "bar" : {
            "enabled" : "{{user `bar_enabled`}}"
          }
        }
      }

However I need to pass an unquoted true as the parameter, such as:

      "type" : "chef-solo",
      "json" : {
        "foo" : {
          "bar" : {
            "enabled" : {{user `nvidia_enabled`}}
          }
        }
      },

-- 
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/6e9926e9-9f87-4c75-935b-8fdb15d5bc20%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to