biosphere 0.2.6 → 0.2.7
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/bin/biosphere +4 -2
- data/lib/biosphere/cli/terraformplanning.rb +4 -1
- data/lib/biosphere/deployment.rb +4 -2
- data/lib/biosphere/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 1530299d3641fe3b7c3c00f274ac44ccdd0b2d46
|
4
|
+
data.tar.gz: c0626adac909be4cfe32279f90ac919b071347ec
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ce68248981778f66eef1de382bcd461777fdceb86c620e61516242df57a8c0a3a4309879604dbb61dc93af8d12c54ee5f11cb3a92c765cf5f25ad2954b3e8100
|
7
|
+
data.tar.gz: d5372077cd2448b4dbebd8d9e87a2a8b996fe84f2d9580934c8ca2d923e68c7c8af9796ff3445b5e17324799e59b5fef78d2579c7adf6e87349a3a0b0a1ecac6
|
data/bin/biosphere
CHANGED
@@ -233,9 +233,12 @@ elsif ARGV[0] == "commit" && options.src
|
|
233
233
|
end
|
234
234
|
|
235
235
|
# Print the raw terraform output
|
236
|
+
puts "== TERRAFORM PLAN START ==".colorize(:green)
|
236
237
|
puts "\n" + tf_plan_str
|
237
|
-
|
238
|
+
puts "== TERRAFORM PLAN END ==".colorize(:green)
|
239
|
+
puts "\n"
|
238
240
|
# Print our pretty short plan
|
241
|
+
puts "Target group listing:"
|
239
242
|
plan.print
|
240
243
|
|
241
244
|
targets = plan.get_resources.collect { |x| "-target=#{x}" }.join(" ")
|
@@ -330,4 +333,3 @@ else
|
|
330
333
|
STDERR.puts "\nERROR: Unknown command #{ARGV[0]}. Maybe you wanted to do: \"biosphere action #{ARGV[0]}\"?"
|
331
334
|
exit -1
|
332
335
|
end
|
333
|
-
|
@@ -39,6 +39,8 @@ class Biosphere
|
|
39
39
|
out.write "(#{item[:reason]})".colorize(:red)
|
40
40
|
elsif item[:action] == :change
|
41
41
|
out.write "(#{item[:reason]})".colorize(:yellow)
|
42
|
+
elsif item[:action] == :not_picked
|
43
|
+
out.write "(#{item[:reason]})".colorize(:yellow)
|
42
44
|
else
|
43
45
|
out.write "(#{item[:reason]}) unknown action: #{item[:action]}".colorize(:red)
|
44
46
|
end
|
@@ -124,7 +126,7 @@ class Biosphere
|
|
124
126
|
resource_to_target_group_map = {}
|
125
127
|
|
126
128
|
resources_not_in_any_target_group = {}
|
127
|
-
deployment.
|
129
|
+
deployment.all_resources.each do |resource|
|
128
130
|
belong_to_target_group = false
|
129
131
|
resource_name = resource[:type] + "." + resource[:name]
|
130
132
|
|
@@ -190,6 +192,7 @@ class Biosphere
|
|
190
192
|
# Relaunches are more complex: we need to bucket resources based on group, so that we can later pick just one change from each group
|
191
193
|
changes[:relaunches].each do |change|
|
192
194
|
group = resource_to_target_group_map[change]
|
195
|
+
puts "group #{group} for change #{change}"
|
193
196
|
if group
|
194
197
|
group_changes_map[group] = (group_changes_map[group] ||= []) << change
|
195
198
|
elsif resources_not_in_any_target_group[change]
|
data/lib/biosphere/deployment.rb
CHANGED
@@ -5,7 +5,7 @@ class Biosphere
|
|
5
5
|
|
6
6
|
class Deployment
|
7
7
|
|
8
|
-
attr_reader :export, :name, :_settings, :feature_manifests, :target_groups, :resources
|
8
|
+
attr_reader :export, :name, :_settings, :feature_manifests, :target_groups, :resources, :all_resources
|
9
9
|
attr_accessor :state, :node
|
10
10
|
|
11
11
|
def initialize(parent, name, settings={})
|
@@ -44,11 +44,12 @@ class Biosphere
|
|
44
44
|
if @parent.is_a?(::Biosphere::Suite)
|
45
45
|
@parent.register(self)
|
46
46
|
@target_groups = {}
|
47
|
-
|
47
|
+
@all_resources = []
|
48
48
|
elsif @parent
|
49
49
|
@node = @parent.node
|
50
50
|
@state = @parent.state
|
51
51
|
@export = @parent.export
|
52
|
+
@all_resources = @parent.all_resources
|
52
53
|
@target_groups = @parent.target_groups
|
53
54
|
|
54
55
|
@parent.register(self)
|
@@ -141,6 +142,7 @@ class Biosphere
|
|
141
142
|
end
|
142
143
|
|
143
144
|
@resources << resource
|
145
|
+
@all_resources << resource
|
144
146
|
|
145
147
|
end
|
146
148
|
|
data/lib/biosphere/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: biosphere
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Juho Mäkinen
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-05-
|
11
|
+
date: 2017-05-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|