summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Smith <tsmith@chef.io>2019-05-24 10:07:15 -0700
committerGitHub <noreply@github.com>2019-05-24 10:07:15 -0700
commit03efc937799f098abdf4f8244bd3c00d6fd62ab2 (patch)
treea1c956f0a0ed0bb702603adeffecdac85089d6cc
parent40d62b29e6072a212036ce1953657bb7dc4ab399 (diff)
parentd4e0929011155d939c384f62820b524ed6646951 (diff)
downloadchef-03efc937799f098abdf4f8244bd3c00d6fd62ab2.tar.gz
Merge pull request #8582 from chilcote/launch_events
launchd: add launch_events property
-rw-r--r--lib/chef/provider/launchd.rb1
-rw-r--r--lib/chef/resource/launchd.rb3
2 files changed, 4 insertions, 0 deletions
diff --git a/lib/chef/provider/launchd.rb b/lib/chef/provider/launchd.rb
index 2530e6f779..880c5d9aa7 100644
--- a/lib/chef/provider/launchd.rb
+++ b/lib/chef/provider/launchd.rb
@@ -195,6 +195,7 @@ class Chef
"inetd_compatibility" => "inetdCompatibility",
"init_groups" => "InitGroups",
"keep_alive" => "KeepAlive",
+ "launch_events" => "LaunchEvents",
"launch_only_once" => "LaunchOnlyOnce",
"limit_load_from_hosts" => "LimitLoadFromHosts",
"limit_load_to_hosts" => "LimitLoadToHosts",
diff --git a/lib/chef/resource/launchd.rb b/lib/chef/resource/launchd.rb
index 331124bf13..d9d2af7edf 100644
--- a/lib/chef/resource/launchd.rb
+++ b/lib/chef/resource/launchd.rb
@@ -161,6 +161,9 @@ class Chef
introduced: "12.14",
description: "Keep a job running continuously (true) or allow demand and conditions on the node to determine if the job keeps running (false)."
+ property :launch_events, [ Hash ],
+ description: "Specify higher-level event types to be used as launch-on-demand event sources."
+
property :launch_only_once, [ TrueClass, FalseClass ],
description: "Specify if a job can be run only one time. Set this value to true if a job cannot be restarted without a full machine reboot."