chef 17.7.22-universal-mingw32 → 17.7.29-universal-mingw32

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: de3500fef9fe640bfe7197594dcf426e223aa7f2780c7672abad2f307596236a
4
- data.tar.gz: 4b30b19efeea5d20d3b039dd2a04e8a1b478750676961a92d25f2e5041c5cac6
3
+ metadata.gz: e74e8e30d2f450bdc6669c974de84230639fd5d15b62417373be2e2ea924524a
4
+ data.tar.gz: d820bfac3769b1cb3ccc8e3f098a3b40ef333cb13c419cf54d36f78d6640f2f0
5
5
  SHA512:
6
- metadata.gz: 203a3046e662b1ecd6584e6d82284da42053787cdc133dba3fc859c642008d16f82a58f3ee97e75621cca97cb8d2d3f246927905de54697b1729f5c52b4c7d90
7
- data.tar.gz: 6b4faa047fdfe94f1223716980e5399e8a3343eb9d00305d65e05414a8957f1ba42fcf29b327123aff5b293f28c3b86cb92992ea2961811a25ddb1d31898bb62
6
+ metadata.gz: 7da62f0de32d26cf3c86c3fa87fac6cbbe281cf07fab283a1082bda1d5465734719164f3c3ecdc0dc37d3405b8de29e7f6358f3ca18a9c7a91b10677233a74a5
7
+ data.tar.gz: e5f431699ae781e44b4f20cf78af0802953a2e5ab5a3b7d648e0524de001e6ed2accf6eb9776e403a886f4f6b8b83c9da073bbbe0e1f012b98291d8f2a730b09
@@ -108,7 +108,7 @@ class Chef
108
108
  headers["Authorization"] = "Bearer #{new_resource.auth_token}" if new_resource.auth_token
109
109
 
110
110
  Chef::JSONCompat.parse(http.get(url, headers))
111
- rescue Net::HTTPServerException
111
+ rescue Net::HTTPClientException
112
112
  nil
113
113
  end
114
114
  end
@@ -75,6 +75,7 @@ class Chef
75
75
  file cert_path do
76
76
  content new_resource.certificate
77
77
  mode "0640"
78
+ sensitive new_resource.sensitive
78
79
  end
79
80
  end
80
81
 
@@ -52,8 +52,8 @@ class Chef
52
52
  property :name, String, default: "install habitat",
53
53
  description: "Name of the resource block. This has no impact other than logging."
54
54
 
55
- property :install_url, String, default: "https://raw.githubusercontent.com/habitat-sh/habitat/master/components/hab/install.sh",
56
- description: "URL to the install script, default is from the [habitat repo](https://raw.githubusercontent.com/habitat-sh/habitat/master/components/hab/install.sh) ."
55
+ property :install_url, String, default: "https://raw.githubusercontent.com/habitat-sh/habitat/main/components/hab/install.sh",
56
+ description: "URL to the install script, default is from the [habitat repo](https://raw.githubusercontent.com/habitat-sh/habitat/main/components/hab/install.sh) ."
57
57
 
58
58
  property :bldr_url, String,
59
59
  description: "Optional URL to an alternate Habitat Builder."
@@ -17,6 +17,7 @@
17
17
 
18
18
  require_relative "../resource"
19
19
  require "chef-utils/dist" unless defined?(ChefUtils::Dist)
20
+ require "corefoundation" if RUBY_PLATFORM.match?(/darwin/)
20
21
  autoload :Plist, "plist"
21
22
 
22
23
  class Chef
@@ -135,31 +136,27 @@ class Chef
135
136
  CF::Preferences.get(new_resource.key, new_resource.domain, new_resource.user, new_resource.host)
136
137
  end
137
138
 
138
- action_class do
139
- require "corefoundation" if RUBY_PLATFORM.match?(/darwin/)
140
-
141
- # Return valid hostname based on the input from host property
142
- def to_cf_host(value)
143
- case value
144
- when :all
145
- CF::Preferences::ALL_HOSTS
146
- when :current
147
- CF::Preferences::CURRENT_HOST
148
- else
149
- value
150
- end
139
+ # Return valid hostname based on the input from host property
140
+ def to_cf_host(value)
141
+ case value
142
+ when :all
143
+ CF::Preferences::ALL_HOSTS
144
+ when :current
145
+ CF::Preferences::CURRENT_HOST
146
+ else
147
+ value
151
148
  end
149
+ end
152
150
 
153
- # Return valid username based on the input from user property
154
- def to_cf_user(value)
155
- case value
156
- when :all
157
- CF::Preferences::ALL_USERS
158
- when :current
159
- CF::Preferences::CURRENT_USER
160
- else
161
- value
162
- end
151
+ # Return valid username based on the input from user property
152
+ def to_cf_user(value)
153
+ case value
154
+ when :all
155
+ CF::Preferences::ALL_USERS
156
+ when :current
157
+ CF::Preferences::CURRENT_USER
158
+ else
159
+ value
163
160
  end
164
161
  end
165
162
  end
data/lib/chef/version.rb CHANGED
@@ -23,7 +23,7 @@ require_relative "version_string"
23
23
 
24
24
  class Chef
25
25
  CHEF_ROOT = File.expand_path("..", __dir__)
26
- VERSION = Chef::VersionString.new("17.7.22")
26
+ VERSION = Chef::VersionString.new("17.7.29")
27
27
  end
28
28
 
29
29
  #
@@ -16,7 +16,7 @@
16
16
  #
17
17
  require "spec_helper"
18
18
 
19
- describe Chef::Resource::MacosUserDefaults, :macos_only, requires_root: true do
19
+ describe Chef::Resource::MacosUserDefaults, :macos_only do
20
20
  def create_resource
21
21
  node = Chef::Node.new
22
22
  events = Chef::EventDispatch::Dispatcher.new
@@ -51,4 +51,18 @@ describe Chef::Resource::ChefClientTrustedCertificate do
51
51
  expect(provider.cert_path).to match(%r{trusted_certs/something.pem$})
52
52
  end
53
53
  end
54
+
55
+ describe "sensitive attribute" do
56
+ context "should be insensitive by default" do
57
+ it { expect(resource.sensitive).to(be_falsey) }
58
+ end
59
+
60
+ context "when set" do
61
+ before { resource.sensitive(true) }
62
+
63
+ it "should be set on the resource" do
64
+ expect(resource.sensitive).to(be_truthy)
65
+ end
66
+ end
67
+ end
54
68
  end
@@ -17,7 +17,7 @@
17
17
 
18
18
  require "spec_helper"
19
19
 
20
- describe Chef::Resource::MacosUserDefaults, :macos_only, requires_root: true do
20
+ describe Chef::Resource::MacosUserDefaults, :macos_only do
21
21
  let(:test_value) { "fakest_key_value" }
22
22
  let(:test_key) { "fakest_key" }
23
23
  let(:node) { Chef::Node.new }
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: chef
3
3
  version: !ruby/object:Gem::Version
4
- version: 17.7.22
4
+ version: 17.7.29
5
5
  platform: universal-mingw32
6
6
  authors:
7
7
  - Adam Jacob
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-10-25 00:00:00.000000000 Z
11
+ date: 2021-10-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: chef-config
@@ -16,28 +16,28 @@ dependencies:
16
16
  requirements:
17
17
  - - '='
18
18
  - !ruby/object:Gem::Version
19
- version: 17.7.22
19
+ version: 17.7.29
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - '='
25
25
  - !ruby/object:Gem::Version
26
- version: 17.7.22
26
+ version: 17.7.29
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: chef-utils
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
31
  - - '='
32
32
  - !ruby/object:Gem::Version
33
- version: 17.7.22
33
+ version: 17.7.29
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - '='
39
39
  - !ruby/object:Gem::Version
40
- version: 17.7.22
40
+ version: 17.7.29
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: train-core
43
43
  requirement: !ruby/object:Gem::Requirement