summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLamont Granquist <lamont@scriptkiddie.org>2021-11-04 14:58:35 -0700
committerLamont Granquist <lamont@scriptkiddie.org>2021-11-04 14:58:35 -0700
commit1beb4a809d8be7386027bff6dfcf031585d61bb3 (patch)
treea54128d96aaa074cb7101ea644acbc2c301002ce
parent3e3aeef2cdd4f7c47416df3f51d06398adb6ea7b (diff)
downloadchef-lcg/umask-attribute.tar.gz
Add string to umask attributelcg/umask-attribute
fixes #11932 Signed-off-by: Lamont Granquist <lamont@scriptkiddie.org>
-rw-r--r--lib/chef/resource.rb2
-rw-r--r--lib/chef/resource/execute.rb3
-rw-r--r--lib/chef/resource/launchd.rb3
3 files changed, 1 insertions, 7 deletions
diff --git a/lib/chef/resource.rb b/lib/chef/resource.rb
index e7ac91594f..746efb5fd4 100644
--- a/lib/chef/resource.rb
+++ b/lib/chef/resource.rb
@@ -454,7 +454,7 @@ class Chef
# @param arg [String] The umask to apply while converging the resource.
# @return [Boolean] The umask to apply while converging the resource.
#
- property :umask, String,
+ property :umask, [String, Integer],
desired_state: false,
introduced: "16.2",
description: "Set a umask to be used for the duration of converging the resource. Defaults to `nil`, which means to use the system umask. Unsupported on Windows because Windows lacks a direct equivalent to UNIX's umask."
diff --git a/lib/chef/resource/execute.rb b/lib/chef/resource/execute.rb
index 602453c7eb..5c84eb3835 100644
--- a/lib/chef/resource/execute.rb
+++ b/lib/chef/resource/execute.rb
@@ -517,9 +517,6 @@ class Chef
name_property: true,
description: "An optional property to set the command to be executed if it differs from the resource block's name. Note: Use the **execute** resource to run a single command. Use multiple **execute** resource blocks to run multiple commands."
- property :umask, [ String, Integer ],
- description: "The file mode creation mask, or umask."
-
property :creates, String,
description: "Prevent a command from creating a file when that file already exists."
diff --git a/lib/chef/resource/launchd.rb b/lib/chef/resource/launchd.rb
index d5be5f3a44..9729b29085 100644
--- a/lib/chef/resource/launchd.rb
+++ b/lib/chef/resource/launchd.rb
@@ -238,9 +238,6 @@ class Chef
property :time_out, Integer,
description: "The amount of time (in seconds) a job may be idle before it times out. If no value is specified, the default timeout value for launchd will be used."
- property :umask, Integer,
- description: "A decimal value to pass to `umask` before running a job."
-
property :username, String,
description: "When launchd is run as the root user, the user to run the job as."