We''ve been doing a puppet parser validate <file> before putting a manifest into production. however that doesn''t seem to catch dependency loops. Is there a way to test for such problems? -- 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/-/u8A8EPWAIyQJ. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
On Tue, Sep 18, 2012 at 11:58 AM, LTH <ltharris@vcu.edu> wrote:> We''ve been doing a > > puppet parser validate <file> > > before putting a manifest into production. however that doesn''t seem to > catch dependency loops. > > Is there a way to test for such problems?Not without compiling a full catalog. On the plus side, `puppet master` has an option to compile a catalog for you, so you could substitute that into place in favour of just `puppet parser validate`. On the minus side, you need a full set of modules, manifests, etc in place to test with for that, and you need to run it for a specific node, so you better have the YAML (or inventory_service, or whatever) facts available for it. Part of the challenge is that there is no way to statically determine if a loop exists or not without fully evaluating the DSL. (In some cases it may be possible, but never generically, thanks to the ENC, hiera, and create_resources.) -- Daniel Pittman ⎋ Puppet Labs Developer – http://puppetlabs.com ♲ Made with 100 percent post-consumer electrons -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
On Tue, Sep 18, 2012 at 11:58 AM, LTH <ltharris@vcu.edu> wrote:> We''ve been doing a > > puppet parser validate <file> > > before putting a manifest into production. however that doesn''t seem to > catch dependency loops. > > Is there a way to test for such problems?As Daniel says, it''s not just a matter of parsing the manifests but going further and building a catalog. rspec-puppet [1] compiles a catalog and will catch dependency loops. [1] http://rspec-puppet.com/ -Jeff -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
I would suggest looking into using Vagrant for local testing before pushing code. Vagrant up.com -- 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/-/zVMH02fI2rkJ. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.