diff options
author | Hugo Hörnquist <hugo@lysator.liu.se> | 2023-06-20 22:32:35 +0200 |
---|---|---|
committer | Hugo Hörnquist <hugo@lysator.liu.se> | 2023-06-20 22:32:35 +0200 |
commit | 5b100712c03c9233ec89d6a30d568d3d296eab1a (patch) | |
tree | 9d6e7e92728e1370cade5bc5bbf97896d4e5ba58 /manifests/confdir.pp | |
parent | fixes (diff) | |
download | concourse-5b100712c03c9233ec89d6a30d568d3d296eab1a.tar.gz concourse-5b100712c03c9233ec89d6a30d568d3d296eab1a.tar.xz |
fixes
Diffstat (limited to 'manifests/confdir.pp')
-rw-r--r-- | manifests/confdir.pp | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/manifests/confdir.pp b/manifests/confdir.pp new file mode 100644 index 0000000..70be54c --- /dev/null +++ b/manifests/confdir.pp @@ -0,0 +1,23 @@ +# @summary Sets up configuration directory +# +# As noted elsewhere, concourse wants to be configured through environment variables. +# This creates a directory to store the environment variables in. +# +# @param conf_dir +# Where additional environment files will be stored. +# @param purge_conf_dir +# Should the directory mentioned in `conf_dir` be purged. If this +# is true then decomissioning sub-configurations are done by simply +# removing that resource. +# @api private +class concourse::confdir ( + Stdlib::Absolutepath $conf_dir = '/etc/conf.d/concourse.d', + Boolean $purge_conf_dir = true, + Enum['absent', 'present'] $ensure = 'present', +) { + file { $conf_dir: + ensure => if $ensure == 'present' { 'directory' } else { 'absent' }, + purge => $purge_conf_dir, + recurse => true, + } +} |