Hi All,
I have been bashing my head against the wall with this template problem.
I have tried numerous variations on this, but the gist of it is this:
When I create a template of over 105 (or so) lines, I get various strange
error messages. Those messages vary depending on very tiny changes with
the template (such as adding a single text line or variable).
Sometimes the errors look like this:
err: Could not retrieve configuration: Could not understand configuration:
parse error on line 1928, col 11: ` 0''
Sometimes they are much longer like this:
err: Could not retrieve configuration: Could not understand configuration:
parse error on line 1989, col -3: ` owner: root
group: root
path:
"/tmp/rhel4base_test_junkapp_test_rollup.pp.test"
line: 34
type: file
tags:
- junkapp_test_application_rollup_classfile
- main
- rhel4base.mydomain.org
- rhel4base_applications
- ws61_app_rollup
- file
collectable: false
name:
"/tmp/rhel4base_test_junkapp_test_rollup.pp.test"
name: junkapp_test_application_rollup_classfile
- !ruby/object:Puppet::TransBucket
type: websphere_6_1_dmgr
children:
- !ruby/object:Puppet::TransObject
file:
"/opt/puppet/config/modules/ws61/manifests/definitions/websphere_6.1_dmgr.pp"
params:
''
Before anyone asks, I created the first error above with a template that
looks like this:
<%= appContext %>
12345678901234567890123456789012345678901234567890
<%= appContext %>
12345678901234567890123456789012345678901234567890
12345678901234567890123456789012345678901234567890
12345678901234567890123456789012345678901234567890
12345678901234567890123456789012345678901234567890
12345678901234567890123456789012345678901234567890
12345678901234567890123456789012345678901234567890
[last line repeated 100 more times]
If I change the beginning of this template to:
<%= appContext %>
12345678901234567890123456789012345678901234567890
<%= appContext %>
<%= appContext %>
12345678901234567890123456789012345678901234567890
12345678901234567890123456789012345678901234567890
12345678901234567890123456789012345678901234567890
[last line repeated 100 more times]
The template works.
If I change it to this:
1<%= appContext %><%= appContext
%>2345678901234567890123456789012345678901234567890
12345678901234567890123456789012345678901234567890
12345678901234567890123456789012345678901234567890
12345678901234567890123456789012345678901234567890
12345678901234567890123456789012345678901234567890
[last line repeated 100 more times]
I get the second (longer) error above.
If I simply delete 10 lines from this last template (ie. the 105 repeated
12345 lines become 95 lines), the error disappears and the template works.
Also, the "gobbledy gook" in the longer version of the error changes
as
the number of lines in the template changes. That stuff appears to be
spilling over from other parts of my puppet configs.
The first error looks similar to defect #610 in the bug tracker, but that
bug is sitting there unresolved. More interesting, if I take out all
variables, the template works just fine.
These are just simple examples to generate the error. Obviously these
aren''t the templates I really need, but they work to illustrate the
problem.
I can''t be the only one who has run into this...
Thanks in advance,
Ed