As epp is the way to go, I'm trying to create all my new templates in 
epp-format.
I have a problem with using conditionals, though.

I have the following conditional in an epp template:
...
<%- if $xxx_yyy == true { -%>
// code here
<%- } -%>
...

When I apply this template with a defined type resource that sets:
...
        xxx_yyy     => true,
...

Nothing happens on that node.
Just to test what the value is of $xxx_yyy, I added "Value variable: <%= 
$xxx_yyy %>" to the templat, but that stays empty.

I call the epp-template with:

content => epp('module/template.epp'),


If I copy the template to template.erb and modify the code as needed:
...
<%- if @sug_saml_enable -%>
// code here
<%- end -%>
...

All is working well when calling the template with:

content => template('module/template.erb'),


What am I doing wrong?
Can someone point me in the right direction?

This is with puppet-agent 4.2.3 and the newest puppetserver.

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to puppet-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/cc95567f-f19b-460c-994f-14426214874c%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to