Thanks a lot to both of you. Effectively, escaping the JSP opening tag with <%% made the trick.
The closing tag needs not to be closed. It is not interpreted in anyway. @John : Thanks for the complementaries informations to do it with ERB. On Monday, July 23, 2012 2:57:13 PM UTC+2, jcbollinger wrote: > > > > On Saturday, July 21, 2012 9:02:50 PM UTC-5, Yanis Guenane wrote: >> >> Hi All, >> >> I was trying to templatize some JSP page I would like to dynamically >> generates but it looks like puppet doesn't like it. >> >> Common JSP tags are <% ... %> so I guess it's getting confused between >> regular tags and jsp's one. >> >> This is an example of the trace it is givin me : >> >> /etc/puppet/modules/xxx/templates/webapps/xxx/yyy/Mantle.jsp:1:in >>> `result': compile error (SyntaxError) >>> /etc/puppet/modules/xxx/templates/webapps/xxx/yyy/Mantle.jsp:1: syntax >>> error, unexpected tIDENTIFIER, expecting $end >>> >> >> Is there any know way to deal with JSP pages ? >> > > ERB is the Ruby analog to the templating aspects of JSP, even sporting > overlapping syntax (as you discovered). If you must create a JSP page by > processing a template with ERB, then any literal JSP tag delimiters in the > ERB template must be escaped. The Ruby docs for class ERB give the syntax: > <%% maps to <%, and %%> maps to %>. > > You'll have to decide whether that's worthwhile, or whether to look for a > better way. For sure, if there are many JSP tags or much scriptlet code in > your JSP, then it is already difficult enough to read and maintain before > you convert it into an ERB template. > > > John > > -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To view this discussion on the web visit https://groups.google.com/d/msg/puppet-users/-/-ZMSFkockmwJ. 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.
