rubber 2.10.0 → 2.10.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +1 -0
- data/CHANGELOG +17 -2
- data/lib/rubber/cloud/aws.rb +18 -1
- data/lib/rubber/recipes/rubber.rb +21 -2
- data/lib/rubber/recipes/rubber/setup.rb +11 -2
- data/lib/rubber/version.rb +1 -1
- data/templates/passenger_nginx/config/rubber/role/web_tools/nginx-tools.conf +1 -1
- data/test/commands/cron_test.rb +4 -4
- data/test/commands/util_test.rb +3 -3
- metadata +78 -77
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d510dffc3ce1ebe0da4418be8388b37cee5e560c
|
4
|
+
data.tar.gz: b3f19bd63f32e4b18011ecb461c30be71db8f736
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b407b7a98d1ef7160a4fd23d343f581e920c0846ca6a55fc72d3f09c77250135115b1b0b47257791b41a3260e710760cc16d80e0bdb857da7c2bd6f7a27642c3
|
7
|
+
data.tar.gz: d3c39792abf3a2e8f23decb42017fdcabdec80bb1d499d77684eeadfb33121f158a8fc96fbdcb81fa2bb9877b2ee3392c3808e40412a81aa33fa9d04f77c30e9
|
data/.travis.yml
CHANGED
data/CHANGELOG
CHANGED
@@ -1,4 +1,19 @@
|
|
1
|
-
2.10.
|
1
|
+
2 2.10.1 (07/01/2014)
|
2
|
+
|
3
|
+
Improvements:
|
4
|
+
============
|
5
|
+
|
6
|
+
[core] Validate the SSH key configuration. <c6bb4af>
|
7
|
+
|
8
|
+
Bug Fixes:
|
9
|
+
=========
|
10
|
+
|
11
|
+
[core] Fixed syncing security group rules with default VPC. <f4f073a, 1a527bf, 60ff192>
|
12
|
+
[core] Fixed a compatibility problem with Ubuntu 10.04 due to an incompatible core package. <ba6e656>
|
13
|
+
[passenger_nginx] Fixed a problem with a template due to random characters at the end of a line. <fa480ca>
|
14
|
+
|
15
|
+
|
16
|
+
2.10.0 (06/20/2014)
|
2
17
|
|
3
18
|
Improvements:
|
4
19
|
============
|
@@ -23,7 +38,7 @@ Bug Fixes:
|
|
23
38
|
=========
|
24
39
|
|
25
40
|
[core] Fixed template calls to rubber.run_config (a regression introduced in 2.9.0). <66310a5>
|
26
|
-
[graylog]
|
41
|
+
[graylog] Prevent creating the same graylog inputs twice. <ad8a177>
|
27
42
|
[unicorn] Fixed unicorn init script. <4c616ba>
|
28
43
|
|
29
44
|
|
data/lib/rubber/cloud/aws.rb
CHANGED
@@ -284,7 +284,24 @@ module Rubber
|
|
284
284
|
rule[:source_groups] ||= []
|
285
285
|
source_group = {}
|
286
286
|
source_group[:account] = rule_group["userId"]
|
287
|
-
|
287
|
+
|
288
|
+
# Amazon doesn't appear to be returning the groupName value when running in a default VPC. It's possible
|
289
|
+
# it's only returned for EC2 Classic. This is distinctly in conflict with the API documents and thus
|
290
|
+
# appears to be a bug on Amazon's end. Nonetheless, we need to handle it because otherwise our security
|
291
|
+
# group rule matching logic will fail and it messes up our users.
|
292
|
+
#
|
293
|
+
# Since every top-level item has both an ID and a name, if we're lacking the groupName we can search
|
294
|
+
# through the items for the one matching the groupId we have and then use its name value. This should
|
295
|
+
# represent precisely the same data.
|
296
|
+
source_group[:name] = if rule_group["groupName"]
|
297
|
+
rule_group["groupName"]
|
298
|
+
elsif rule_group["groupId"]
|
299
|
+
matching_security_group = response.find { |item| item.group_id == rule_group["groupId"] }
|
300
|
+
matching_security_group ? matching_security_group.name : nil
|
301
|
+
else
|
302
|
+
nil
|
303
|
+
end
|
304
|
+
|
288
305
|
rule[:source_groups] << source_group
|
289
306
|
end if ip_item["groups"]
|
290
307
|
|
@@ -88,10 +88,29 @@ namespace :rubber do
|
|
88
88
|
ssh_keys = if ENV['RUBBER_SSH_KEY']
|
89
89
|
ENV['RUBBER_SSH_KEY'].split(',')
|
90
90
|
else
|
91
|
-
cloud.env.key_file
|
91
|
+
if cloud.env.key_file.nil?
|
92
|
+
fatal "Missing required cloud provider configuration item 'key_file'."
|
93
|
+
else
|
94
|
+
cloud.env.key_file
|
95
|
+
end
|
96
|
+
end
|
97
|
+
|
98
|
+
normalized_ssh_keys = [ssh_keys].flatten.compact
|
99
|
+
|
100
|
+
# Fail-safe check. While we do some validation earlier in the cycle, on the off-chance after all
|
101
|
+
# that, we still have no configured keys, we need to catch it.
|
102
|
+
if normalized_ssh_keys.empty?
|
103
|
+
fatal "No configured SSH keys. Please set the 'key_file' parameter for your cloud provider."
|
104
|
+
end
|
105
|
+
|
106
|
+
# Check that the configuration not only exists, but is also valid.
|
107
|
+
normalized_ssh_keys.each do |key|
|
108
|
+
unless File.exists?(key)
|
109
|
+
fatal "Invalid SSH key path '#{key}': File does not exist.\nPlease check your cloud provider's 'key_file' setting for correctness."
|
110
|
+
end
|
92
111
|
end
|
93
112
|
|
94
|
-
ssh_options[:keys] =
|
113
|
+
ssh_options[:keys] = normalized_ssh_keys
|
95
114
|
ssh_options[:timeout] = fetch(:ssh_timeout, 5)
|
96
115
|
end
|
97
116
|
|
@@ -438,8 +438,17 @@ namespace :rubber do
|
|
438
438
|
'scsitools' # Needed to rescan SCSI channels for any added devices.
|
439
439
|
]
|
440
440
|
|
441
|
-
|
442
|
-
|
441
|
+
install_commands = core_packages.collect do |package|
|
442
|
+
"apt-get -q -o Dpkg::Options::=--force-confold -y --force-yes install #{package} || true"
|
443
|
+
end
|
444
|
+
|
445
|
+
sudo_script 'install_core_packages', <<-ENDSCRIPT
|
446
|
+
export DEBIAN_FRONTEND=noninteractive
|
447
|
+
|
448
|
+
apt-get -q update
|
449
|
+
|
450
|
+
#{install_commands.join("\n")}
|
451
|
+
ENDSCRIPT
|
443
452
|
end
|
444
453
|
|
445
454
|
desc <<-DESC
|
data/lib/rubber/version.rb
CHANGED
@@ -19,7 +19,7 @@ server
|
|
19
19
|
proxy_host = rubber_instances.for_role(settings.role).first.full_name rescue nil
|
20
20
|
next unless proxy_host
|
21
21
|
|
22
|
-
host = "#{name.gsub('_', '-')}-#{rubber_env.full_host}"
|
22
|
+
host = "#{name.gsub('_', '-')}-#{rubber_env.full_host}"
|
23
23
|
host_and_port = "#{host}:#{rubber_env.web_tools_ssl_port}"
|
24
24
|
|
25
25
|
# don't use settings.path here - mapping the host/port is sufficient,
|
data/test/commands/cron_test.rb
CHANGED
@@ -19,7 +19,7 @@ class CronTest < Test::Unit::TestCase
|
|
19
19
|
date = Time.now.tv_sec.to_s
|
20
20
|
out = `#{@rubber} cron echo #{date}`
|
21
21
|
|
22
|
-
assert_equal 0,
|
22
|
+
assert_equal 0, $?.exitstatus
|
23
23
|
assert_equal "", out
|
24
24
|
|
25
25
|
logs = Dir["#{@rubber_root}/log/*.log"]
|
@@ -33,11 +33,11 @@ class CronTest < Test::Unit::TestCase
|
|
33
33
|
date = Time.now.tv_sec.to_s
|
34
34
|
|
35
35
|
out = `#{@rubber} cron echo #{date}`
|
36
|
-
assert_equal 0,
|
36
|
+
assert_equal 0, $?.exitstatus
|
37
37
|
assert_equal "", out
|
38
38
|
|
39
39
|
out = `#{@rubber} cron echo #{date}`
|
40
|
-
assert_equal 0,
|
40
|
+
assert_equal 0, $?.exitstatus
|
41
41
|
assert_equal "", out
|
42
42
|
|
43
43
|
logs = Dir["#{@rubber_root}/log/*.log"]
|
@@ -80,7 +80,7 @@ class CronTest < Test::Unit::TestCase
|
|
80
80
|
|
81
81
|
def test_rubber_cron_output_on_error
|
82
82
|
out = `#{@rubber} cron -- ls -la jkbhbj`
|
83
|
-
assert_not_equal 0,
|
83
|
+
assert_not_equal 0, $?.exitstatus
|
84
84
|
assert_not_equal "", out, "Unexpected output:\n#{out}"
|
85
85
|
end
|
86
86
|
|
data/test/commands/util_test.rb
CHANGED
@@ -13,7 +13,7 @@ class UtilTest < Test::Unit::TestCase
|
|
13
13
|
|
14
14
|
should "generate a key" do
|
15
15
|
out = `#{@rubber} util:obfuscation -g`
|
16
|
-
assert_equal 0,
|
16
|
+
assert_equal 0, $?.exitstatus, "Process failed, output: #{out}"
|
17
17
|
assert_match /Obfuscation key: [^\n\s]+/, out
|
18
18
|
end
|
19
19
|
|
@@ -22,7 +22,7 @@ class UtilTest < Test::Unit::TestCase
|
|
22
22
|
|
23
23
|
fixture_dir = File.expand_path("#{File.dirname(__FILE__)}/../fixtures/secret")
|
24
24
|
out = `#{@rubber} util:obfuscation -f '#{fixture_dir}/secret.yml' -k '#{@key}'`
|
25
|
-
assert_equal 0,
|
25
|
+
assert_equal 0, $?.exitstatus, "Process failed, output: #{out}"
|
26
26
|
assert out.size > 0
|
27
27
|
assert_no_match /secret_key: secret_val/, out
|
28
28
|
|
@@ -30,7 +30,7 @@ class UtilTest < Test::Unit::TestCase
|
|
30
30
|
open(tempfile.path, "w") {|f| f.write(out) }
|
31
31
|
|
32
32
|
out2 = `#{@rubber} util:obfuscation -f '#{tempfile.path}' -k '#{@key}' -d`
|
33
|
-
assert_equal 0,
|
33
|
+
assert_equal 0, $?.exitstatus, "Process failed, output: #{out2}"
|
34
34
|
assert out2.size > 0
|
35
35
|
assert_match /secret_key: secret_val/, out2
|
36
36
|
end
|
metadata
CHANGED
@@ -1,184 +1,184 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rubber
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.10.
|
4
|
+
version: 2.10.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Matt Conway
|
8
8
|
- Kevin Menard
|
9
|
-
autorequire:
|
9
|
+
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2014-
|
12
|
+
date: 2014-07-01 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: capistrano
|
16
|
-
version_requirements: !ruby/object:Gem::Requirement
|
17
|
-
requirements:
|
18
|
-
- - ~>
|
19
|
-
- !ruby/object:Gem::Version
|
20
|
-
version: '2.12'
|
21
16
|
requirement: !ruby/object:Gem::Requirement
|
22
17
|
requirements:
|
23
|
-
- - ~>
|
18
|
+
- - "~>"
|
24
19
|
- !ruby/object:Gem::Version
|
25
20
|
version: '2.12'
|
26
|
-
prerelease: false
|
27
21
|
type: :runtime
|
28
|
-
|
29
|
-
name: net-ssh
|
22
|
+
prerelease: false
|
30
23
|
version_requirements: !ruby/object:Gem::Requirement
|
31
24
|
requirements:
|
32
|
-
- - ~>
|
25
|
+
- - "~>"
|
33
26
|
- !ruby/object:Gem::Version
|
34
|
-
version: '2.
|
27
|
+
version: '2.12'
|
28
|
+
- !ruby/object:Gem::Dependency
|
29
|
+
name: net-ssh
|
35
30
|
requirement: !ruby/object:Gem::Requirement
|
36
31
|
requirements:
|
37
|
-
- - ~>
|
32
|
+
- - "~>"
|
38
33
|
- !ruby/object:Gem::Version
|
39
34
|
version: '2.6'
|
40
|
-
prerelease: false
|
41
35
|
type: :runtime
|
42
|
-
|
43
|
-
name: thor
|
36
|
+
prerelease: false
|
44
37
|
version_requirements: !ruby/object:Gem::Requirement
|
45
38
|
requirements:
|
46
|
-
- -
|
39
|
+
- - "~>"
|
47
40
|
- !ruby/object:Gem::Version
|
48
|
-
version: '
|
41
|
+
version: '2.6'
|
42
|
+
- !ruby/object:Gem::Dependency
|
43
|
+
name: thor
|
49
44
|
requirement: !ruby/object:Gem::Requirement
|
50
45
|
requirements:
|
51
|
-
- -
|
46
|
+
- - ">="
|
52
47
|
- !ruby/object:Gem::Version
|
53
48
|
version: '0'
|
54
|
-
prerelease: false
|
55
49
|
type: :runtime
|
56
|
-
|
57
|
-
name: clamp
|
50
|
+
prerelease: false
|
58
51
|
version_requirements: !ruby/object:Gem::Requirement
|
59
52
|
requirements:
|
60
|
-
- -
|
53
|
+
- - ">="
|
61
54
|
- !ruby/object:Gem::Version
|
62
55
|
version: '0'
|
56
|
+
- !ruby/object:Gem::Dependency
|
57
|
+
name: clamp
|
63
58
|
requirement: !ruby/object:Gem::Requirement
|
64
59
|
requirements:
|
65
|
-
- -
|
60
|
+
- - ">="
|
66
61
|
- !ruby/object:Gem::Version
|
67
62
|
version: '0'
|
68
|
-
prerelease: false
|
69
63
|
type: :runtime
|
70
|
-
|
71
|
-
name: open4
|
64
|
+
prerelease: false
|
72
65
|
version_requirements: !ruby/object:Gem::Requirement
|
73
66
|
requirements:
|
74
|
-
- -
|
67
|
+
- - ">="
|
75
68
|
- !ruby/object:Gem::Version
|
76
69
|
version: '0'
|
70
|
+
- !ruby/object:Gem::Dependency
|
71
|
+
name: open4
|
77
72
|
requirement: !ruby/object:Gem::Requirement
|
78
73
|
requirements:
|
79
|
-
- -
|
74
|
+
- - ">="
|
80
75
|
- !ruby/object:Gem::Version
|
81
76
|
version: '0'
|
82
|
-
prerelease: false
|
83
77
|
type: :runtime
|
84
|
-
|
85
|
-
name: fog
|
78
|
+
prerelease: false
|
86
79
|
version_requirements: !ruby/object:Gem::Requirement
|
87
80
|
requirements:
|
88
|
-
- -
|
81
|
+
- - ">="
|
89
82
|
- !ruby/object:Gem::Version
|
90
|
-
version: '
|
83
|
+
version: '0'
|
84
|
+
- !ruby/object:Gem::Dependency
|
85
|
+
name: fog
|
91
86
|
requirement: !ruby/object:Gem::Requirement
|
92
87
|
requirements:
|
93
|
-
- - ~>
|
88
|
+
- - "~>"
|
94
89
|
- !ruby/object:Gem::Version
|
95
90
|
version: '1.6'
|
96
|
-
prerelease: false
|
97
91
|
type: :runtime
|
98
|
-
|
99
|
-
name: json
|
92
|
+
prerelease: false
|
100
93
|
version_requirements: !ruby/object:Gem::Requirement
|
101
94
|
requirements:
|
102
|
-
- -
|
95
|
+
- - "~>"
|
103
96
|
- !ruby/object:Gem::Version
|
104
|
-
version: '
|
97
|
+
version: '1.6'
|
98
|
+
- !ruby/object:Gem::Dependency
|
99
|
+
name: json
|
105
100
|
requirement: !ruby/object:Gem::Requirement
|
106
101
|
requirements:
|
107
|
-
- -
|
102
|
+
- - ">="
|
108
103
|
- !ruby/object:Gem::Version
|
109
104
|
version: '0'
|
110
|
-
prerelease: false
|
111
105
|
type: :runtime
|
112
|
-
|
113
|
-
name: rake
|
106
|
+
prerelease: false
|
114
107
|
version_requirements: !ruby/object:Gem::Requirement
|
115
108
|
requirements:
|
116
|
-
- -
|
109
|
+
- - ">="
|
117
110
|
- !ruby/object:Gem::Version
|
118
111
|
version: '0'
|
112
|
+
- !ruby/object:Gem::Dependency
|
113
|
+
name: rake
|
119
114
|
requirement: !ruby/object:Gem::Requirement
|
120
115
|
requirements:
|
121
|
-
- -
|
116
|
+
- - ">="
|
122
117
|
- !ruby/object:Gem::Version
|
123
118
|
version: '0'
|
124
|
-
prerelease: false
|
125
119
|
type: :development
|
126
|
-
|
127
|
-
name: test-unit
|
120
|
+
prerelease: false
|
128
121
|
version_requirements: !ruby/object:Gem::Requirement
|
129
122
|
requirements:
|
130
|
-
- -
|
123
|
+
- - ">="
|
131
124
|
- !ruby/object:Gem::Version
|
132
125
|
version: '0'
|
126
|
+
- !ruby/object:Gem::Dependency
|
127
|
+
name: test-unit
|
133
128
|
requirement: !ruby/object:Gem::Requirement
|
134
129
|
requirements:
|
135
|
-
- -
|
130
|
+
- - ">="
|
136
131
|
- !ruby/object:Gem::Version
|
137
132
|
version: '0'
|
138
|
-
prerelease: false
|
139
133
|
type: :development
|
140
|
-
|
141
|
-
name: shoulda-context
|
134
|
+
prerelease: false
|
142
135
|
version_requirements: !ruby/object:Gem::Requirement
|
143
136
|
requirements:
|
144
|
-
- -
|
137
|
+
- - ">="
|
145
138
|
- !ruby/object:Gem::Version
|
146
139
|
version: '0'
|
140
|
+
- !ruby/object:Gem::Dependency
|
141
|
+
name: shoulda-context
|
147
142
|
requirement: !ruby/object:Gem::Requirement
|
148
143
|
requirements:
|
149
|
-
- -
|
144
|
+
- - ">="
|
150
145
|
- !ruby/object:Gem::Version
|
151
146
|
version: '0'
|
152
|
-
prerelease: false
|
153
147
|
type: :development
|
154
|
-
|
155
|
-
name: mocha
|
148
|
+
prerelease: false
|
156
149
|
version_requirements: !ruby/object:Gem::Requirement
|
157
150
|
requirements:
|
158
|
-
- -
|
151
|
+
- - ">="
|
159
152
|
- !ruby/object:Gem::Version
|
160
153
|
version: '0'
|
154
|
+
- !ruby/object:Gem::Dependency
|
155
|
+
name: mocha
|
161
156
|
requirement: !ruby/object:Gem::Requirement
|
162
157
|
requirements:
|
163
|
-
- -
|
158
|
+
- - ">="
|
164
159
|
- !ruby/object:Gem::Version
|
165
160
|
version: '0'
|
166
|
-
prerelease: false
|
167
161
|
type: :development
|
168
|
-
|
169
|
-
name: awesome_print
|
162
|
+
prerelease: false
|
170
163
|
version_requirements: !ruby/object:Gem::Requirement
|
171
164
|
requirements:
|
172
|
-
- -
|
165
|
+
- - ">="
|
173
166
|
- !ruby/object:Gem::Version
|
174
167
|
version: '0'
|
168
|
+
- !ruby/object:Gem::Dependency
|
169
|
+
name: awesome_print
|
175
170
|
requirement: !ruby/object:Gem::Requirement
|
176
171
|
requirements:
|
177
|
-
- -
|
172
|
+
- - ">="
|
178
173
|
- !ruby/object:Gem::Version
|
179
174
|
version: '0'
|
180
|
-
prerelease: false
|
181
175
|
type: :development
|
176
|
+
prerelease: false
|
177
|
+
version_requirements: !ruby/object:Gem::Requirement
|
178
|
+
requirements:
|
179
|
+
- - ">="
|
180
|
+
- !ruby/object:Gem::Version
|
181
|
+
version: '0'
|
182
182
|
description: |2
|
183
183
|
The rubber plugin enables relatively complex multi-instance deployments of RubyOnRails applications to
|
184
184
|
Amazon's Elastic Compute Cloud (EC2). Like capistrano, rubber is role based, so you can define a set
|
@@ -194,8 +194,8 @@ executables:
|
|
194
194
|
extensions: []
|
195
195
|
extra_rdoc_files: []
|
196
196
|
files:
|
197
|
-
- .gitignore
|
198
|
-
- .travis.yml
|
197
|
+
- ".gitignore"
|
198
|
+
- ".travis.yml"
|
199
199
|
- CHANGELOG
|
200
200
|
- Gemfile
|
201
201
|
- Gemfile.1.8.7
|
@@ -694,24 +694,25 @@ files:
|
|
694
694
|
homepage: https://github.com/rubber/rubber
|
695
695
|
licenses: []
|
696
696
|
metadata: {}
|
697
|
-
post_install_message:
|
697
|
+
post_install_message:
|
698
698
|
rdoc_options: []
|
699
699
|
require_paths:
|
700
700
|
- lib
|
701
701
|
required_ruby_version: !ruby/object:Gem::Requirement
|
702
702
|
requirements:
|
703
|
-
- -
|
703
|
+
- - ">="
|
704
704
|
- !ruby/object:Gem::Version
|
705
705
|
version: '0'
|
706
706
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
707
707
|
requirements:
|
708
|
-
- -
|
708
|
+
- - ">="
|
709
709
|
- !ruby/object:Gem::Version
|
710
710
|
version: '0'
|
711
711
|
requirements: []
|
712
712
|
rubyforge_project: rubber
|
713
|
-
rubygems_version: 2.
|
714
|
-
signing_key:
|
713
|
+
rubygems_version: 2.2.2
|
714
|
+
signing_key:
|
715
715
|
specification_version: 4
|
716
|
-
summary: A capistrano plugin for managing multi-instance deployments to the cloud
|
716
|
+
summary: A capistrano plugin for managing multi-instance deployments to the cloud
|
717
|
+
(ec2)
|
717
718
|
test_files: []
|