Signed-off-by: James Turnbull <[email protected]>
---
lib/puppet/type/exec.rb | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/lib/puppet/type/exec.rb b/lib/puppet/type/exec.rb
index 606888c..7fa4924 100755
--- a/lib/puppet/type/exec.rb
+++ b/lib/puppet/type/exec.rb
@@ -269,7 +269,7 @@ module Puppet
newparam(:timeout) do
desc "The maximum time the command should take. If the command takes
longer than the timeout, the command is considered to have failed
- and will be stopped. Use any negative number to disable the timeout.
+ and will be stopped. Use 0 to disable the timeout.
The time is specified in seconds."
munge do |value|
@@ -278,6 +278,9 @@ module Puppet
unless value =~ /^[-\d.]+$/
raise ArgumentError, "The timeout must be a number."
end
+ if value =~ /^\-\d+.?\d+$/
+ value = 0
+ end
Float(value)
else
value
@@ -335,7 +338,7 @@ module Puppet
# Pull down the main aliases file
file { \"/etc/aliases\":
source => \"puppet://server/module/aliases\"
- }
+ }
# Rebuild the database, but only when the file changes
exec { newaliases:
--
1.7.3.5
--
You received this message because you are subscribed to the Google Groups
"Puppet Developers" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/puppet-dev?hl=en.