On 04/23/14 07:54, Gabriel Filion wrote: > On 22/04/14 08:20 PM, Joachim Schrod wrote: >> # Ghostscript default paper size >> file_line { 'Ghostscript A4' : >> path => '/usr/share/ghostscript/9.05/Resource/Init/gs_init.ps', >> match => '^% /DEFAULTPAPERSIZE \(a4\)', >> line => '/DEFAULTPAPERSIZE (a4) def' >> } >> >> The error message is >> >> Error: Failed to apply catalog: Validation of File_line[Ghostscript A4] >> failed: When providing a 'match' parameter, the value must be a regex that >> matches against the value of your 'line' parameter at >> /etc/puppet/modules/npc/manifests/commons.pp:30 >> Wrapped exception: >> When providing a 'match' parameter, the value must be a regex that matches >> against the value of your 'line' parameter > > maybe by "regex" it means that you need to enclose it in / characters: > > http://www.ruby-doc.org/core-2.1.1/Regexp.html > > e.g. : match => /^% /DEFAULTPAPERSIZE \(a4\)/, > > I'm not sure whether you need the quotes, too.. I'd try without first..
Without quotes, the error message is Syntax error at '/'; expected '}' With quotes and slashes, the error message is the same as before, quoted above. I don't understand why the match regex must match the line value. Joachim -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- Joachim Schrod, Roedermark, Germany Email: jsch...@acm.org -- 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/lj7tkc%24k32%241%40ger.gmane.org. For more options, visit https://groups.google.com/d/optout.