diff options
author | David Schmitt <david@schmitt.edv-bus.at> | 2009-05-31 21:14:37 +0200 |
---|---|---|
committer | David Schmitt <david@schmitt.edv-bus.at> | 2009-05-31 21:14:37 +0200 |
commit | 53d0fde15feb30777a6929cada73d5f6e6ceb513 (patch) | |
tree | 1c81f431393991beabff6011a337dce2d0d76931 /manifests/defines/config_file.pp | |
parent | 9a2c68367f8ac75ce52e315253d28f6710a80702 (diff) |
Major cleanup of the common module
* improve documentation on all defines
* rename modules_dir to module_dir and modules_file to module_file
* create $module_dir_path to achieve DRY-ness
* silence the lsb_release stuff
* improve concatenated_file to use an intermediate file, improving reliability
and decoupling the updateing from notifying our peers.
* remove serveral functions that were moved to puppet proper:
- sha1 => sha1
- gsub,substitute,slash_escape => regsubst
Diffstat (limited to 'manifests/defines/config_file.pp')
-rw-r--r-- | manifests/defines/config_file.pp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/manifests/defines/config_file.pp b/manifests/defines/config_file.pp index cd6ccc3..8d93e0a 100644 --- a/manifests/defines/config_file.pp +++ b/manifests/defines/config_file.pp @@ -2,6 +2,8 @@ # Copyright (C) 2007 David Schmitt <david@schmitt.edv-bus.at> # See LICENSE for the full license granted to you. +# A simple wrapper to give all configuration files common defaults. +# # Usage: # config_file { filename: # content => "....\n", @@ -27,7 +29,11 @@ # notify => Exec["reload-apache2"] # } -define config_file ($content = '', $source = '', $ensure = 'present') { +define config_file ( + $content = '', + $source = '', + $ensure = 'present') +{ file { $name: ensure => $ensure, # keep old versions on the server |