On Wednesday, August 28, 2013 7:39:00 PM UTC-5, Dennis Jacobfeuerborn wrote: > > Hi, > I'm looking into writing proper modules and starting off with "puppet > module generate" but it seems the tool uses an invalid name for the > directory. > When i specify "mymodule" as a name it tells me I need to use a dash > separated name and when I use "myname-mymodule" then the module > gets generated but using the "mymodule" class as either "mymodule" or > "myname-mymodule" only results in puppet not being able to find the class. > > The fix seems to be to rename the directory to "mymodule". After that the > "mymodule" class can be used in manifests. > Am I doing something wrong or why does the puppet module tool create > directories with an invalid name? > >
The convention for creating and exchanging modules is to use a root directory name formed as the module tool is asking you to do. When you install such a module into your module path, you are expected to remove the "myname-" part of the directory name. I think the module tool normally handles that for you when you use it for module installation. Evidently, the module tool's 'generate' function is intended to generate an uninstalled module rather than an installed one. John -- 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 post to this group, send email to puppet-users@googlegroups.com. Visit this group at http://groups.google.com/group/puppet-users. For more options, visit https://groups.google.com/groups/opt_out.