On 06/21/2010 11:07 AM, CraftyTech wrote:
Hello All,
Can you guys point out to me, how do I do a case statement within
a template? i.g: my.cnf
max_allowed_packet=<% case ($memorysize<=4) = 8M, case
($memorysize<=8) = 16M)?
I've tried different combinations, but so far no luck. The syntax
checker coughs up hair balls....
Thanks,
Henry
Anything inside <% %> uses standard ruby coding, however it does *not*
put stdout into the file. Take this for example:
<% if somevar == 100 -%>
variable="this"
<% else -%>
variable="that"
<% end -%>
This is how you would print out a setting for a variable.
--
--
Joe McDonagh
Operations Engineer
AIM: YoosingYoonickz
IRC: joe-mac on freenode
"When the going gets weird, the weird turn pro."
--
You received this message because you are subscribed to the Google Groups "Puppet
Users" group.
To post to this group, send email to puppet-us...@googlegroups.com.
To unsubscribe from this group, send email to
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/puppet-users?hl=en.