chef-config 12.18.31 → 12.19.33
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/chef-config/config.rb +12 -12
- data/lib/chef-config/path_helper.rb +1 -1
- data/lib/chef-config/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8b5536e204ae1a9ff503c782bb2754c264e1703d
|
4
|
+
data.tar.gz: 6be79e3469c89cc5e9e2925af6d95ae36834501c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: a39aff765a4011ea2802eb41d1982af504ffd1730869b784486256ef5520ad34a09bd5d07e4a99c0dbd890a7070d306bb207e07c73202a1d5314b89796e3ffb7
|
7
|
+
data.tar.gz: 1a7d512ff843f25e940bb907f65d5d6c99eced4eb92e2f797950c34a4d31020bcafad7019fac6f988f77981273f1bb67088e3fbe67c955619fc22b96f0276dea
|
data/lib/chef-config/config.rb
CHANGED
@@ -45,7 +45,7 @@ module ChefConfig
|
|
45
45
|
#
|
46
46
|
# +filename+ is used for context in stacktraces, but doesn't need to be the name of an actual file.
|
47
47
|
def self.from_string(string, filename)
|
48
|
-
|
48
|
+
instance_eval(string, filename, 1)
|
49
49
|
end
|
50
50
|
|
51
51
|
def self.inspect
|
@@ -142,16 +142,16 @@ module ChefConfig
|
|
142
142
|
# that upload or download files (such as knife upload, knife role from file,
|
143
143
|
# etc.) work.
|
144
144
|
default :chef_repo_path do
|
145
|
-
if
|
146
|
-
if
|
147
|
-
File.expand_path("..",
|
145
|
+
if configuration[:cookbook_path]
|
146
|
+
if configuration[:cookbook_path].kind_of?(String)
|
147
|
+
File.expand_path("..", configuration[:cookbook_path])
|
148
148
|
else
|
149
|
-
|
149
|
+
configuration[:cookbook_path].map do |path|
|
150
150
|
File.expand_path("..", path)
|
151
151
|
end
|
152
152
|
end
|
153
153
|
elsif configuration[:cookbook_artifact_path]
|
154
|
-
File.expand_path("..",
|
154
|
+
File.expand_path("..", configuration[:cookbook_artifact_path])
|
155
155
|
else
|
156
156
|
cache_path
|
157
157
|
end
|
@@ -205,7 +205,7 @@ module ChefConfig
|
|
205
205
|
# Defaults to <chef_repo_path>/cookbooks. If chef_repo_path
|
206
206
|
# is not specified, this is set to [/var/chef/cookbooks, /var/chef/site-cookbooks]).
|
207
207
|
default(:cookbook_path) do
|
208
|
-
if
|
208
|
+
if configuration[:chef_repo_path]
|
209
209
|
derive_path_from_chef_repo_path("cookbooks")
|
210
210
|
else
|
211
211
|
Array(derive_path_from_chef_repo_path("cookbooks")).flatten +
|
@@ -412,10 +412,10 @@ module ChefConfig
|
|
412
412
|
default(:chef_server_root) do
|
413
413
|
# if the chef_server_url is a path to an organization, aka
|
414
414
|
# 'some_url.../organizations/*' then remove the '/organization/*' by default
|
415
|
-
if
|
416
|
-
|
417
|
-
elsif
|
418
|
-
|
415
|
+
if configuration[:chef_server_url] =~ /\/organizations\/\S*$/
|
416
|
+
configuration[:chef_server_url].split("/")[0..-3].join("/")
|
417
|
+
elsif configuration[:chef_server_url] # default to whatever chef_server_url is
|
418
|
+
configuration[:chef_server_url]
|
419
419
|
else
|
420
420
|
"https://localhost:443"
|
421
421
|
end
|
@@ -566,7 +566,7 @@ module ChefConfig
|
|
566
566
|
# Initialize openssl
|
567
567
|
def self.init_openssl
|
568
568
|
if fips
|
569
|
-
|
569
|
+
enable_fips_mode
|
570
570
|
end
|
571
571
|
end
|
572
572
|
|
@@ -187,7 +187,7 @@ module ChefConfig
|
|
187
187
|
#
|
188
188
|
# See self.all_homes.
|
189
189
|
def self.home(*args)
|
190
|
-
@@home_dir ||=
|
190
|
+
@@home_dir ||= all_homes { |p| break p }
|
191
191
|
if @@home_dir
|
192
192
|
path = File.join(@@home_dir, *args)
|
193
193
|
block_given? ? (yield path) : path
|
data/lib/chef-config/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: chef-config
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 12.
|
4
|
+
version: 12.19.33
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Adam Jacob
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-02-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: mixlib-shellout
|
@@ -170,7 +170,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
170
170
|
version: '0'
|
171
171
|
requirements: []
|
172
172
|
rubyforge_project:
|
173
|
-
rubygems_version: 2.6.
|
173
|
+
rubygems_version: 2.6.10
|
174
174
|
signing_key:
|
175
175
|
specification_version: 4
|
176
176
|
summary: Chef's default configuration and config loading
|