summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMicah Anderson <micah@riseup.net>2013-05-23 12:46:35 -0400
committerMicah Anderson <micah@riseup.net>2013-05-23 12:46:35 -0400
commit694e08d2e26706013b65b47f146585eb6abd2a99 (patch)
tree2b9eb4f7b5145bf64f41c86e55a0260d55f62a95
parent8e1e75bafd5a9ae8dc67ee73eebbaafbf120d07e (diff)
parent7959f69b8c3006553cda22e482f96eb44e9304c6 (diff)
Merge remote-tracking branch 'micah/develop' into develop
-rw-r--r--puppet/modules/try/manifests/file.pp13
1 files changed, 12 insertions, 1 deletions
diff --git a/puppet/modules/try/manifests/file.pp b/puppet/modules/try/manifests/file.pp
index 406c0b7a..47a8c269 100644
--- a/puppet/modules/try/manifests/file.pp
+++ b/puppet/modules/try/manifests/file.pp
@@ -18,7 +18,10 @@ define try::file (
file { "$name":
ensure => $ensure,
target => $target,
- require => Exec["check_${name}"],
+ require => $require ? {
+ undef => Exec["check_${name}"],
+ default => [ $require, Exec["check_${name}"] ]
+ },
loglevel => info;
}
}
@@ -37,6 +40,10 @@ define try::file (
exec { "restore_${name}":
command => $command,
cwd => $file_dirname,
+ require => $require ? {
+ undef => undef,
+ default => [ $require ]
+ },
loglevel => info;
}
} else {
@@ -44,6 +51,10 @@ define try::file (
unless => "/usr/bin/test -e '${target}'",
command => $command,
cwd => $file_dirname,
+ require => $require ? {
+ undef => undef,
+ default => [ $require ]
+ },
loglevel => info;
}
}