On 17 September 2015 at 15:27, Arnau <[email protected]> wrote: > Hi, > > https://docs.puppetlabs.com/puppet/latest/reference/modules_fundamentals.html > > Maybe start with: > > puppet module generate user-modulename .... >
puppet module generate assumes a pure Puppet module, rather than one using the Ruby API. The larger skeleton I maintain has the trappings of a Ruby module, but it's fairly large at this point: https://github.com/garethr/puppet-module-skeleton > you'll get the basic stuff. > > HTH, > > 2015-09-17 8:46 GMT+02:00 <[email protected]>: >> >> I have some experience handling puppet modules but this time I wrote some >> code in Ruby that I'd like to port to a custom puppet module. I already have >> read puppetlabs documentation( puppetforge, Beginner's guide )about writing >> custom modules but I still don't get a basic idea to build from zero a dummy >> custom puppet module to test it. >> >> >> Do you know where can I find some practical examples to build a dummy >> custom puppet module? >> The following is a pretty small/simple native type and provider. https://github.com/garethr/garethr-digitalocean It's not the best code but it works and it's not complicated, so for getting started purposes it's potentially a nice start to follow as long as you know a little Ruby. The following blog posts also give a good introduction to some of the concepts that are worth understanding. http://garylarizza.com/blog/2013/11/25/fun-with-providers/ http://garylarizza.com/blog/2013/11/26/fun-with-providers-part-2/ http://garylarizza.com/blog/2013/12/15/seriously-what-is-this-provider-doing/ And do feel frree to post code in gists for feedback here. I'd love to know what you're building too. Gareth >> -- >> 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 [email protected]. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/puppet-users/4cca7c51-e51a-46be-8b3f-ff8fc802d038%40googlegroups.com. >> For more options, visit https://groups.google.com/d/optout. > > > -- > 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 [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/puppet-users/CAM69jx9Zhfd4npRUc26csPoF%2BnOcKTo5keHO-Zk3jWYB0mMTGQ%40mail.gmail.com. > > For more options, visit https://groups.google.com/d/optout. -- Gareth Rushgrove @garethr devopsweekly.com morethanseven.net garethrushgrove.com -- 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 [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CAFi_6yK1NfyujAcDBiDZGsmf42bntuGuY9UwoZUA9CYDTq4d4w%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
