On 6/01/11 10:48 AM, Patrick wrote:
On Jan 5, 2011, at 2:52 PM, Michael Knox wrote:
It would be neat if puppet could use tar.gz's as a source, instead of just bare
directory trees. So I've lodged a feature request:
https://projects.puppetlabs.com/issues/5786
Many of my manifests for applications need to cover the following process: 1.
Download .tar.gz to host
2. Expand .tar.gz
3. Whatever install process is required
As an example (assuming Feature Request#5783):
file {“/srv/<application>”:
source => “<puppet|http>:///<path>/<application>.tar.gz”,
expand => true,
recurse => true,
ensure => directory,
}
This would create a directory, and populate it with the contents of .tar.gz It
would also keep the contents in sync with .tar.gz.
Expand is a new option for file, but perhaps this could be inferred (and the
option not needed) as ensure => directory and source is a file.
I'm curious what you're thinking of.
Would this be a File? (The directory contents are checked each time.) or would
this be a Package (assume that the contents are right if the file on the server
hasn't changed)
I was thinking of FIle, I hadn't thought of it as a Package.
My concern was ensuring that the contents on the disk match the source.
Both the exec {"expand_tar_file": onlyif => some test }, and
package{"some app": } have the same risk ... what's on the disk has
changed, and won't be refreshed as our metadata say's that it's all good.
I guess the onlyif for the exec could be a checksum ... currently I only
do a basic check to see if it's been downloaded and expanded.
--
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.