What should this do?
$array = [ "one", "two" ]
$greeting = [ "hello", "howdy" ]
@file { "host_$array$greeting" }
or this?
$array = [ "one", "two" ]
@file { "$array_blah" }
seems like we would need delimiters
"host_${array}_${greeting}"
and some form of expansion control.
Should it expand zipper-wise or combinatorially?
Probably all of that belongs in functions,
not in the resource or string syntax.
--
vagn
On 05/20/2011 04:15 PM, Randall Hansen wrote:
http://projects.puppetlabs.com/issues/7598
If your goal is this (pseudo-code):
@file { "host_one" }
@file { "host_two" }
You should be able to say this:
$array = [ "one", "two" ]
@file { "host_$array" }
Instead of this:
@file { "host_one", "host_two" }
Please comment on the ticket or reply here, whichever you prefer.
Thanks!
r
P.S. This is in response to feedback from my "Improving the Puppet
DSL" session at Puppet Camp EU, 2011. This ticket isn't a promise we
will take action, but we could very much like comment and discussion
from you good people.
--
You received this message because you are subscribed to the Google Groups "Puppet
Users" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/puppet-users?hl=en.