Puppet: System Administration Automated

Support

Ticket #1134 (closed enhancement: fixed)

Opened 6 months ago

Last modified 6 months ago

Type ref update to highlight that onlyif can take an array.

Reported by: mike Assigned to: luke
Priority: normal Milestone:
Component: documentation Version: 0.24.2
Severity: trivial Keywords: exec onlyif
Cc: Triage Stage: Ready for checkin
Attached Patches: Code Complexity: Trivial

Description

diff --git a/lib/puppet/type/exec.rb b/lib/puppet/type/exec.rb index 5bb3158..367a353 100755 --- a/lib/puppet/type/exec.rb +++ b/lib/puppet/type/exec.rb @@ -384,6 +384,13 @@ module Puppet

Note that this command follows the same rules as the main command, which is to say that it must be fully qualified if the path is not set.

+ + Also note that onlyif can take an array as its value, eg: + onlyif => [\"test -f /tmp/file1\", \"test -f /tmp/file2\"] + + This will only run the exec if /all/ conditions in the array return + true. +

"

validate do |cmds|

Attachments

lib_puppet_type_exec.patch (0.7 kB) - added by mike on 03/14/08 18:04:46.

Change History

03/14/08 18:04:46 changed by mike

  • attachment lib_puppet_type_exec.patch added.

03/14/08 18:05:42 changed by mike

  • severity changed from normal to trivial.
  • patch changed from None to Code.

Apologies - patch attached properly now...

03/17/08 17:13:06 changed by jamtur01

  • owner changed from community to luke.
  • complexity changed from Unknown to Trivial.
  • stage changed from Unreviewed to Ready for checkin.

Applied in commit [80be3e6dab0b05f36cf68070ac98a90b274497e2] in branch 0.24.x

03/20/08 17:33:35 changed by luke

  • status changed from new to closed.
  • resolution set to fixed.

I'm testing out rebasing; the actual commit is now [4cc18ed43637efa9064a302b76d8565c0f706ebe].