rig 0.6.6 → 0.6.7

Sign up to get free protection for your applications and to get access to all the features.
@@ -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
 
@@ -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[:dns_subdomain]}"
22
+ n = "#{name}1.#{environment}.#{Rig.get_config(:dns_subdomain)}"
23
23
  chef = Rig.config[:chef] ? true : false
24
24
 
25
25
  unless flavor
@@ -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[:dns_subdomain]}/ }
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[:dns_subdomain]}"
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[: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)
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[:dns_subdomain]}.#{Rig.get_config(:dns_zone)}")
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[:dns_subdomain]}.#{Rig.get_config(:dns_zone)}")
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)
@@ -3,7 +3,7 @@ unless defined?(Rig::Version)
3
3
  module Version
4
4
  MAJOR = 0
5
5
  MINOR = 6
6
- TINY = 6
6
+ TINY = 7
7
7
  STRING = [MAJOR, MINOR, TINY].join('.')
8
8
  end
9
9
  end
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.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-21 00:00:00.000000000 Z
12
+ date: 2012-09-25 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: clamp