Re: [Puppet Users] addition to wiki/FunctionReference

David Schmitt
Tue, 08 Dec 2009 10:57:15 -0000

On 08.12.2009 11:31, Andrew Schulman wrote:
> I added some text to
> http://reductivelabs.com/trac/puppet/wiki/FunctionReference.  It explains
that
> functions get evaluated at compile time, before execution time, and that
this
> matters if you''re using functions whose values depend on the
results of your
> manifests.
>
>
http://reductivelabs.com/trac/puppet/wiki/FunctionReference?action=diff&version=26&old_version=25
>
> I''d appreciate it if someone would check the accuracy of what I
wrote, and if
> it''s deemed to be accurate and useful, apply it upstream so that
it will stay in
> the wiki.


Not quite: The functions are actually evaluated on the server. You
example of using file($path) and file { $path: ... } will never work,
since the file() function will read $path on the puppetmaster, while the
File[$path] resource will manage $path on the client.


Regards, DavidS