summaryrefslogtreecommitdiffstats
path: root/lib/puppet/util
diff options
context:
space:
mode:
authorBrice Figureau <brice-puppet@daysofwonder.com>2010-03-13 14:57:39 +0100
committerJames Turnbull <james@lovedthanlost.net>2010-03-25 11:54:08 +1100
commit19863c07f983ec181fb81c797ee8b9c8d335e18c (patch)
tree6f457f4e7ff5eb2b7a0aebf3baf61664ab147dd2 /lib/puppet/util
parentfd76142b314c390205570d02383607ff91b23391 (diff)
downloadpuppet-19863c07f983ec181fb81c797ee8b9c8d335e18c.tar.gz
puppet-19863c07f983ec181fb81c797ee8b9c8d335e18c.tar.xz
puppet-19863c07f983ec181fb81c797ee8b9c8d335e18c.zip
Fix #2929 - Allow checksum to be "none"
File checksum is "md5" by default. When managing local files (not sourced or content) it might be desirable to not checksum files, especially when managing deep hierarchies containing many files. This patch allows to write such manifests: file { "/path/to/deep/hierarchy": owner => brice, recurse => true, checksum => none } Then puppet(d) won't checksum those files, just manage their ownership. Signed-off-by: Brice Figureau <brice-puppet@daysofwonder.com>
Diffstat (limited to 'lib/puppet/util')
-rw-r--r--lib/puppet/util/checksums.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/puppet/util/checksums.rb b/lib/puppet/util/checksums.rb
index 98bf5de8f..39477ee2b 100644
--- a/lib/puppet/util/checksums.rb
+++ b/lib/puppet/util/checksums.rb
@@ -68,6 +68,11 @@ module Puppet::Util::Checksums
File.stat(filename).send(:ctime)
end
+ # Return a "no checksum"
+ def none_file(filename)
+ ""
+ end
+
private
# Perform an incremental checksum on a file.