[Puppet Users] Re: How to pass parameter from puppet-client ?

AJ
Wed, 28 May 2008 03:43:00 -0000

''lo!
Eric Heydrick wrote:
>
> On Tue, 27 May 2008, tung dang wrote:
>
>
>> Hi all,
>> Firstly, thank for your answer
>> As i know tags is used for resources, that means all the tags has to
define in the manifests before using
>> Can puppet-client pass the variable parameter to puppetmaster ?
>> Have anyone ever done it?
>> Can i write a program, module to capture tags, that doesn''t
exist in the manifest ?
>>
The way to achieve what you''re trying to do is use some kind of
classification system that Puppet can plug into (I''m thinking
iClassify)
so that you can query relevant information when building templates, etc.

There is no way to get arbitrary data back from puppet apart from the
suggestion below
> Puppet will make variables for environment variables named FACTER_. So if
> you wanted a variable called $foo in your manifest run puppetd like
> "FACTER_foo=bar puppetd ...".  You can tie that to tags so that
defining a
> variable in the environment defines a tag:
>
> if $foo {
>   tag(dosomething)
> }
>
> if tagged(dosomething) {
>   dosomething
> }
>
> -Eric
>

Regards,

AJ