[Pkg-puppet-devel] Bug#573430: Bug#573430: provide $vardir/modules

micah anderson micah at debian.org
Mon Mar 15 17:40:16 UTC 2010


On Fri, 12 Mar 2010 22:07:22 +0100, martin f krafft <madduck at debian.org> wrote:
> also sprach micah anderson <micah at debian.org> [2010.03.12.2036 +0100]:
> > The second is dynamically generated file concatentation bits that are
> > created by a module, and then assembled into a configuration file. These
> > are typically done in /var/lib/puppet/modules, at least if you are using
> > this method that DavidS uses. I dont think that this directory should be
> > created by the package.
> 
> Almost: these are typically done in
> /var/lib/puppet/modules/$MODULENAME, and since puppet's file type
> does not create parent directories, no module can really ever use
> /var/lib/puppet/modules/$MODULENAME unless it can rely on
> /var/lib/puppet/modules to be there. So unless the admin (or the
> Debian package) creates the directory, each module has to jump
> through hoops[0] before being able to use the directory, because of
> the stupid puppet limitation that an instance cannot be multiply
> defined.
> 
> Right now, DavidS' common module creates the parent, which means
> I'll either have to require the common module, or conflict with it,
> but I cannot merely supplement it.

You can require DavidS' common module, you can conflict with it, and you
most certainly can supplement it. I'm not sure why you think you cannot
supplement it.

There are other ways to accomplish this[0] that don't use
/var/lib/puppet/modules/$MODULENAME, so those methods are going to get a
worthless directory created because some people use DavidS' method? 

I still think that creating /var/lib/puppet/modules seems outside the
scope of the package to do this, this is what you use puppet
for. However, I do think that /etc/puppet/modules should be created as
it is more germane to puppet itself.

> 0. e.g. exec { "mkdir --parent /var/lib/puppet/modules" }

This is a funny way to use puppet. Why don't you simply do:

file { "/var/lib/puppet/modules": ensure => directory, require => Package[puppet]; }

micah


     
0. personally, i think this one is better: http://www.devco.net/archives/2010/03/12/puppet_concat_20100312.php
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 835 bytes
Desc: not available
URL: <http://lists.alioth.debian.org/pipermail/pkg-puppet-devel/attachments/20100315/bb6b2a8f/attachment.pgp>


More information about the Pkg-puppet-devel mailing list