mathie
2010-Jan-26 04:52 UTC
[Puppet Users] Where can I use generate() in additional to file/content?
The docs does not mention in which type I can use the function generate (). I know I can use with file { content => generate("bin/sh","/tmp/ server_script.sh"). Where else I can use generate() ? http://docs.reductivelabs.com/references/stable/function.html#generate Thanks -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
James Turnbull
2010-Jan-26 07:10 UTC
Re: [Puppet Users] Where can I use generate() in additional to file/content?
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 26/01/10 3:52 PM, mathie wrote:> The docs does not mention in which type I can use the function generate > (). I know I can use with file { content => generate("bin/sh","/tmp/ > server_script.sh"). Where else I can use generate() ?It''s a function that returns a value - you can use pretty much anywhere in your manifests that it makes sense - assuming you remember that functions only execute on the server. Regards James Turnbull - -- Author of: * Pro Linux System Administration (http://tinyurl.com/linuxadmin) * Pulling Strings with Puppet (http://tinyurl.com/pupbook) * Pro Nagios 2.0 (http://tinyurl.com/pronagios) * Hardening Linux (http://tinyurl.com/hardeninglinux) -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.7 (Darwin) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/ iQEVAwUBS16VSiFa/lDkFHAyAQJSawf/W9Bin4sBqkWLDk60dCpo8SBo1lOHTePZ kA73ZaYHqO2Yh2N9uS3MrUpknGdOhQMaQxoiuFOpGqE/t7dtNTrNt46C6ZXuBP75 af010e9qHUkjOuVlfAL/+6/aF2ppTAOPuWexBPKa3fXRmZ1HcipjcgqBpkeVoTZc HqMZ3E6nvqSCbk1iOXDl1OTDZYiKS1iEVD4PRhUw3LBzDsW+u2yBpNIjodoFSA2P uATkyxMxs6wJqkt9yq45fyWy388h7IzN31X/MfRPtZ2oHnaPj26b6Oqtm3fMWhcg 0vW9sbtYE9td9JFexwW7xv6MWQbheX68A8ASkG3jf6qowaZv2ZaG2w==3yQG -----END PGP SIGNATURE----- -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.