chef-metal-fog 0.1 → 0.2
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
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 927b70a0bdd36d1e004c168d90d71c9e18bf6608
|
4
|
+
data.tar.gz: e8152c40c1ec3c0b866d6189dfc0df1da81fa30f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0f389c377ec27b9cc391e635e045e8141ac9615d41e3a5beeba721e5dd3166b61f57576f4a6dca33f22ad5415ba7a89b0121d3bd5ab9d16995bf84966543592e
|
7
|
+
data.tar.gz: 7b807bdf75b5062c328c29ef3b41d216979a67456240e3a494c00a69920ce71c03a40baacba01d239b2420007647a90f211ea15aba3af59791d93b9874df965d
|
@@ -8,7 +8,9 @@ require 'chef_metal/convergence_strategy/install_msi'
|
|
8
8
|
require 'chef_metal/convergence_strategy/install_cached'
|
9
9
|
require 'chef_metal/transport/ssh'
|
10
10
|
require 'fog'
|
11
|
+
require 'fog/core'
|
11
12
|
require 'fog/compute'
|
13
|
+
require 'fog/aws'
|
12
14
|
|
13
15
|
module ChefMetalFog
|
14
16
|
# Provisions machines in vagrant.
|
@@ -152,19 +154,12 @@ module ChefMetalFog
|
|
152
154
|
# Set up the modified node data
|
153
155
|
provisioner_output = node['normal']['provisioner_output'] || {
|
154
156
|
'provisioner_url' => provisioner_url,
|
155
|
-
'provisioner_version' =>
|
157
|
+
'provisioner_version' => ChefMetalFog::VERSION,
|
156
158
|
'creator' => aws_login_info[1]
|
157
159
|
}
|
158
160
|
|
159
161
|
if provisioner_output['provisioner_url'] != provisioner_url
|
160
|
-
|
161
|
-
Chef::Log.warn "The upgrade from chef-metal 0.3 to 0.4 changed the provisioner URL format! Metal will assume you are in fact using the same AWS account, and modify the provisioner URL to match."
|
162
|
-
provisioner_output['provisioner_url'] = provisioner_url
|
163
|
-
provisioner_output['provisioner_version'] ||= ChefMetal::VERSION
|
164
|
-
provisioner_output['creator'] ||= aws_login_info[1]
|
165
|
-
else
|
166
|
-
raise "Switching providers for a machine is not currently supported! Use machine :destroy and then re-create the machine on the new action_handler."
|
167
|
-
end
|
162
|
+
raise "Switching a machine's provider from #{provisioner_output['provisioner_url']} to #{provisioner_url} for is not currently supported! Use machine :destroy and then re-create the machine on the new provisioner."
|
168
163
|
end
|
169
164
|
|
170
165
|
node['normal']['provisioner_output'] = provisioner_output
|
@@ -332,7 +327,6 @@ module ChefMetalFog
|
|
332
327
|
@base_bootstrap_options_for[machine] = current_base_bootstrap_options
|
333
328
|
end
|
334
329
|
|
335
|
-
|
336
330
|
def compute
|
337
331
|
@compute ||= Fog::Compute.new(compute_options)
|
338
332
|
end
|
@@ -466,11 +460,17 @@ module ChefMetalFog
|
|
466
460
|
def convergence_strategy_for(node)
|
467
461
|
if node['normal']['provisioner_options'] && node['normal']['provisioner_options']['is_windows']
|
468
462
|
@windows_convergence_strategy ||= begin
|
469
|
-
|
463
|
+
options = {}
|
464
|
+
provisioner_options = node['normal']['provisioner_options'] || {}
|
465
|
+
options[:chef_client_timeout] = provisioner_options['chef_client_timeout'] if provisioner_options.has_key?('chef_client_timeout')
|
466
|
+
ChefMetal::ConvergenceStrategy::InstallMsi.new(options)
|
470
467
|
end
|
471
468
|
else
|
472
469
|
@unix_convergence_strategy ||= begin
|
473
|
-
|
470
|
+
options = {}
|
471
|
+
provisioner_options = node['normal']['provisioner_options'] || {}
|
472
|
+
options[:chef_client_timeout] = provisioner_options['chef_client_timeout'] if provisioner_options.has_key?('chef_client_timeout')
|
473
|
+
ChefMetal::ConvergenceStrategy::InstallCached.new(options)
|
474
474
|
end
|
475
475
|
end
|
476
476
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: chef-metal-fog
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: '0.
|
4
|
+
version: '0.2'
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- John Keiser
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-04-
|
11
|
+
date: 2014-04-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: chef
|