On 2010-05-12 18:10, Ken wrote:

External node classifiers can only specify variables and classes,
not resources.  Big limitation.

I personally like the separation. In our case we want to provide a
'model/data only' approach at that layer - and hide 'code logic'. Of
course parameterized classes (coming in rowlf I believe) will make
things look nicer as well so I can avoid the global vars.

Problem is that then each time you want to add a resource, you must
write a class for it, so you haven't gained much.  You get increased
flexibility in deciding on which node(s) the resource should be applied,
but not which resources exists.

As an example, consider a web hosting provider, that has thousands of
virtual hosts in their lighttpd/nginx/apache configs.  They have a Puppet
define for managing a virtual web host, used something like this:

    virtual_web_host {
        "www.customer-4711.com":
            docroot => "/mnt/fileserver-17/4711",
            mod_python => enabled,
            upload_methods => ["ftp","scp"],
            bandwidth_limit_per_minute => 60,    # Mbyte/minute
            bandwidth_limit_per_month => 130000, # Mbyte/month
            ensure => enabled;
    }

or whatever parameters makes sense.  Each time a new customer is signed
on, the sales people add it to their customer database with information
about which services the customer has paid for (ftp and scp access to
upload web pages, and allowed to run Python scripts).  At first glance
this seems to be exactly what external node scripts could help you with.
Except that it can't, because you still need to ask the sysadmins to load
"customers.pp" into their Emacs and write a new class 'customer-4711'
containing the above stansa.  You can use the external node classifier to
*move* the virtual web hosts from node to node in response to changing
demands, but it doesn't help you defining which virtual hosts you have.


Why *should* I use an external node classifier?  I would just need to
invent a description language for describing my nodes, when there
already is an existing one in Puppet.

I'm guessing you've seen puppet-dashboard right? It avoids the need to
develop your own thing if you don't want to.

http://www.puppetlabs.com/puppet/related-projects/dashboard/ starts with
saying "The Puppet Dashboard is a web interface [...]".  At about that
point I lost interrest in it...  I'm absolutely *not* interrested in a
web GUI to configure my nodes.  What I might be interrested in, is a
*language* that lets me say things like nodes with names on the form "n$N"
where $N is an integer have certain resources, and if $N is in the range
1-384 they have yet a few more resources, but if $N is in the range 385-500
they get another set of extra resources.  Or some other strange criteria
that I don't really know at the moment.  Does puppet-dashboard really have
such a language?  What little documentation I have seen for it doesn't
really show how to manage node configurations using it.

I don't really have such needs at the moment.  Or rather, those few such
needs I do have, can fairly easily be handled inside the normal Puppet
language, and I don't change those criteria frequently enough to warrant
having it in a database outside of my normal manifests.


        /Bellman

--
You received this message because you are subscribed to the Google Groups "Puppet 
Users" group.
To post to this group, send email to puppet-us...@googlegroups.com.
To unsubscribe from this group, send email to 
puppet-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/puppet-users?hl=en.

Reply via email to