rig 0.6.6 → 0.6.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.
- data/CHANGELOG.md +8 -0
- data/lib/rig/command/server.rb +1 -1
- data/lib/rig/model/dns.rb +1 -1
- data/lib/rig/model/environment.rb +5 -5
- data/lib/rig/version.rb +1 -1
- metadata +2 -2
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,13 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
+
## v0.6.6:
|
4
|
+
* use common Balancer#sticky code for command and environment#create
|
5
|
+
* wrap plugin calls with rescue block
|
6
|
+
* allow idempotent calls to template load
|
7
|
+
* make the subdomain configurable (instead of just always using '.env.')
|
8
|
+
* clean up balancer list output
|
9
|
+
* remove some debug stuff
|
10
|
+
|
3
11
|
## v0.6.5:
|
4
12
|
* get stickiness code working properly, have to add policy to balancer and associate with listener
|
5
13
|
|
data/lib/rig/command/server.rb
CHANGED
@@ -19,7 +19,7 @@ module Rig
|
|
19
19
|
|
20
20
|
def execute
|
21
21
|
# figure out if there are others of this role, if there are add a number to name to distinguish.
|
22
|
-
n = "#{name}1.#{environment}.#{Rig.get_config
|
22
|
+
n = "#{name}1.#{environment}.#{Rig.get_config(:dns_subdomain)}"
|
23
23
|
chef = Rig.config[:chef] ? true : false
|
24
24
|
|
25
25
|
unless flavor
|
data/lib/rig/model/dns.rb
CHANGED
@@ -52,7 +52,7 @@ module Rig
|
|
52
52
|
|
53
53
|
def remove_environment(name)
|
54
54
|
zone = zone(Rig.get_config(:dns_zone))
|
55
|
-
list = zone.records.all.select {|e| e.attributes[:name] =~ /\.#{name}\.#{Rig.get_config
|
55
|
+
list = zone.records.all.select {|e| e.attributes[:name] =~ /\.#{name}\.#{Rig.get_config(:dns_subdomain)}/ }
|
56
56
|
list.each do |e|
|
57
57
|
Rig::Log.info "record: #{e.attributes[:name]}"
|
58
58
|
destroy(e.attributes[:name])
|
@@ -65,7 +65,7 @@ module Rig
|
|
65
65
|
@template.servers.each do |s|
|
66
66
|
Rig::Log.debug "server[#{s.count}]= #{s.inspect}"
|
67
67
|
1.upto(s.count) do |i|
|
68
|
-
n = "#{s.name}#{i}.#@name.#{Rig.get_config
|
68
|
+
n = "#{s.name}#{i}.#@name.#{Rig.get_config(:dns_subdomain)}"
|
69
69
|
Rig::Log.debug " name= #{n}"
|
70
70
|
userdata = s.userdata || Rig.get_config(:userdata)
|
71
71
|
o = {
|
@@ -111,8 +111,8 @@ module Rig
|
|
111
111
|
@balancers << balancer
|
112
112
|
|
113
113
|
if b.primary
|
114
|
-
Rig::Log.info ".. primary: #{name}.#{Rig.get_config
|
115
|
-
Rig::Model::Dns.create("#{name}.#{Rig.get_config
|
114
|
+
Rig::Log.info ".. primary: #{name}.#{Rig.get_config(:dns_subdomain)}.#@zone #{balancer.attributes[:dns_name]}"
|
115
|
+
Rig::Model::Dns.create("#{name}.#{Rig.get_config(:dns_subdomain)}.#@zone", balancer.attributes[:dns_name], :ttl => 30)
|
116
116
|
end
|
117
117
|
end
|
118
118
|
end
|
@@ -168,11 +168,11 @@ module Rig
|
|
168
168
|
roles = @servers.collect { |s| s.tags['Role'] }.compact
|
169
169
|
roles.each do |r|
|
170
170
|
Rig::Log.info "removing role balancer dns (#{r})"
|
171
|
-
Rig::Model::Dns.destroy("#{r}.#{name}.#{Rig.get_config
|
171
|
+
Rig::Model::Dns.destroy("#{r}.#{name}.#{Rig.get_config(:dns_subdomain)}.#{Rig.get_config(:dns_zone)}")
|
172
172
|
end
|
173
173
|
|
174
174
|
Rig::Log.info "removing primary dns"
|
175
|
-
Rig::Model::Dns.destroy("#{name}.#{Rig.get_config
|
175
|
+
Rig::Model::Dns.destroy("#{name}.#{Rig.get_config(:dns_subdomain)}.#{Rig.get_config(:dns_zone)}")
|
176
176
|
|
177
177
|
Rig::Log.info "destroying servers"
|
178
178
|
Rig::Model::Instance.destroy(@servers)
|
data/lib/rig/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rig
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.6.
|
4
|
+
version: 0.6.7
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2012-09-
|
12
|
+
date: 2012-09-25 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: clamp
|