rubber 1.5.7 → 1.5.8

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 CHANGED
@@ -1,3 +1,10 @@
1
+ 1.5.7
2
+ -----
3
+
4
+ allow access to calling generator so can determine stuff like fake_root <fa6354c> [Matt Conway]
5
+ refactor create using refresh <12df4c4> [Matt Conway]
6
+ save config in refresh <cdb8344> [Matt Conway]
7
+
1
8
  1.5.6
2
9
  -----
3
10
 
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.5.7
1
+ 1.5.8
@@ -6,7 +6,7 @@ on :load do
6
6
  set :application, rubber_env.app_name
7
7
  set :runner, rubber_env.app_user
8
8
  set :deploy_to, "/mnt/#{application}-#{RUBBER_ENV}"
9
- set :copy_exclude, [".git/*", "log/*"]
9
+ set :copy_exclude, [".git/*", ".bundle/*", "log/*"]
10
10
  end
11
11
 
12
12
  # Use a simple directory tree copy here to make demo easier.
@@ -6,7 +6,7 @@
6
6
  # cron clears out enviroment variables, so we need to add these in
7
7
  # to make sure we are running the correct ruby (rvm env vars, plus paths)
8
8
  <%- ENV.select {|k, v| k =~ /rvm|ruby|bundler|gem|path/i }.each do |k, v| -%>
9
- <%= k %>=<%= v %>
9
+ <%= k %>='<%= v %>'
10
10
  <%- end -%>
11
11
 
12
12
  MAILTO=<%= rubber_env.admin_email %>
@@ -12,7 +12,7 @@
12
12
  packages: [build-essential, git-core, subversion, curl, autoconf, bison, ruby, zlib1g-dev, libssl-dev, libreadline5-dev, libxml2-dev]
13
13
 
14
14
  # REQUIRED: the version of rvm itself
15
- rvm_version: 0.1.38
15
+ rvm_version: 1.0.1
16
16
 
17
17
  # REQUIRED: Set to the rvm version string for the ruby version you wish to use
18
18
  # Run "rvm list known" to see the list of possible options
@@ -75,12 +75,12 @@ cloud_providers:
75
75
 
76
76
  # REQUIRED: the ami and instance type for creating instances
77
77
  # The Ubuntu images at http://alestic.com/ work well
78
- # Ubuntu 10.04 Lucid base install 32-bit ami-2d4aa444
79
- # Ubuntu 10.04 Lucid base install 64-bit ami-fd4aa494
78
+ # Ubuntu 10.04 Lucid base install 32-bit ami-1437dd7d
79
+ # Ubuntu 10.04 Lucid base install 64-bit ami-4234de2b
80
80
  #
81
- image_id: ami-2d4aa444
82
81
  # m1.small or m1.large or m1.xlarge
83
82
  image_type: m1.small
83
+ image_id: "#{ %w{m1.small c2.medium}.include?(image_type) ? 'ami-1437dd7d' : 'ami-4234de2b' }"
84
84
 
85
85
  # OPTIONAL: EC2 spot instance request support.
86
86
  #
@@ -141,9 +141,7 @@ packages: [postfix, build-essential, git-core, ec2-ami-tools]
141
141
  # OPTIONAL: The gems to install on all instances
142
142
  # You can install a specific version of a gem by using a sub-array of gem, version
143
143
  # For example, gem: [[rails, 2.2.2], open4, aws-s3]
144
- # gems: [rubber, rails, open4, aws-s3]
145
- # The above is the correct line once rails3 has been released
146
- gems: [open4, aws-s3, tzinfo, builder, i18n, memcache-client, rack, rake, rack-test, erubis, mail, text-format, thor, bundler, [rack-mount, 0.4], [rails, 3.0.0.beta3], [rubber, "#{Rubber.version}"]]
144
+ gems: [open4, aws-s3, bundler, [rubber, "#{Rubber.version}"]]
147
145
 
148
146
  # OPTIONAL: A string prepended to shell command strings that cause multi
149
147
  # statement shell commands to fail fast. You may need to comment this out
@@ -6,7 +6,7 @@ on :load do
6
6
  set :application, rubber_env.app_name
7
7
  set :runner, rubber_env.app_user
8
8
  set :deploy_to, "/mnt/#{application}-#{RUBBER_ENV}"
9
- set :copy_exclude, [".git/*", "log/*"]
9
+ set :copy_exclude, [".git/*", ".bundle/*", "log/*"]
10
10
  end
11
11
 
12
12
  # Use a simple directory tree copy here to make demo easier.
@@ -6,7 +6,7 @@
6
6
  # cron clears out enviroment variables, so we need to add these in
7
7
  # to make sure we are running the correct ruby (rvm env vars, plus paths)
8
8
  <%- ENV.select {|k, v| k =~ /rvm|ruby|bundler|gem|path/i }.each do |k, v| -%>
9
- <%= k %>=<%= v %>
9
+ <%= k %>='<%= v %>'
10
10
  <%- end -%>
11
11
 
12
12
  MAILTO=<%= rubber_env.admin_email %>
@@ -12,7 +12,7 @@
12
12
  packages: [build-essential, git-core, subversion, curl, autoconf, bison, ruby, zlib1g-dev, libssl-dev, libreadline5-dev, libxml2-dev]
13
13
 
14
14
  # REQUIRED: the version of rvm itself
15
- rvm_version: 0.1.38
15
+ rvm_version: 1.0.1
16
16
 
17
17
  # REQUIRED: Set to the rvm version string for the ruby version you wish to use
18
18
  # Run "rvm list known" to see the list of possible options
@@ -75,12 +75,12 @@ cloud_providers:
75
75
 
76
76
  # REQUIRED: the ami and instance type for creating instances
77
77
  # The Ubuntu images at http://alestic.com/ work well
78
- # Ubuntu 10.04 Lucid base install 32-bit ami-2d4aa444
79
- # Ubuntu 10.04 Lucid base install 64-bit ami-fd4aa494
78
+ # Ubuntu 10.04 Lucid base install 32-bit ami-1437dd7d
79
+ # Ubuntu 10.04 Lucid base install 64-bit ami-4234de2b
80
80
  #
81
- image_id: ami-2d4aa444
82
81
  # m1.small or m1.large or m1.xlarge
83
82
  image_type: m1.small
83
+ image_id: "#{ %w{m1.small c2.medium}.include?(image_type) ? 'ami-1437dd7d' : 'ami-4234de2b' }"
84
84
 
85
85
  # OPTIONAL: EC2 spot instance request support.
86
86
  #
@@ -141,9 +141,7 @@ packages: [postfix, build-essential, git-core, ec2-ami-tools]
141
141
  # OPTIONAL: The gems to install on all instances
142
142
  # You can install a specific version of a gem by using a sub-array of gem, version
143
143
  # For example, gem: [[rails, 2.2.2], open4, aws-s3]
144
- # gems: [rubber, rails, open4, aws-s3]
145
- # The above is the correct line once rails3 has been released
146
- gems: [open4, aws-s3, tzinfo, builder, i18n, memcache-client, rack, rake, rack-test, erubis, mail, text-format, thor, bundler, [rack-mount, 0.4], [rails, 3.0.0.beta3], [rubber, "#{Rubber.version}"]]
144
+ gems: [open4, aws-s3, bundler, [rubber, "#{Rubber.version}"]]
147
145
 
148
146
  # OPTIONAL: A string prepended to shell command strings that cause multi
149
147
  # statement shell commands to fail fast. You may need to comment this out
@@ -243,15 +243,24 @@ namespace :rubber do
243
243
  instance_item.platform = instance[:platform]
244
244
  rubber_instances.save()
245
245
 
246
- # turn back on root ssh access if we are using root as the capistrano user for connecting
247
- enable_root_ssh(instance_item.external_ip, fetch(:initial_ssh_user, 'ubuntu')) if (user == 'root' && ! instance_item.windows?)
246
+ # weird cap/netssh bug, sometimes just hangs forever on initial connect, so force a timeout
247
+ begin
248
+ Timeout::timeout(10) do
249
+ # turn back on root ssh access if we are using root as the capistrano user for connecting
250
+ enable_root_ssh(instance_item.external_ip, fetch(:initial_ssh_user, 'ubuntu')) if (user == 'root' && ! instance_item.windows?)
248
251
 
249
- # setup amazon elastic ips if configured to do so
250
- setup_static_ips
252
+ # setup amazon elastic ips if configured to do so
253
+ setup_static_ips
251
254
 
252
- # Need to setup aliases so ssh doesn't give us errors when we
253
- # later try to connect to same ip but using alias
254
- setup_local_aliases
255
+ # Need to setup aliases so ssh doesn't give us errors when we
256
+ # later try to connect to same ip but using alias
257
+ setup_local_aliases
258
+ end
259
+ rescue Timeout::Error
260
+ logger.info "timeout in initial connect, retrying"
261
+ retry
262
+ end
263
+
255
264
 
256
265
  # re-load the roles since we may have just defined new ones
257
266
  load_roles() unless env.disable_auto_roles
@@ -253,7 +253,19 @@ namespace :rubber do
253
253
  DESC
254
254
  after "deploy:update_code", "rubber:install_bundler_gems" if Rubber::Util.is_bundler?
255
255
  task :install_bundler_gems do
256
- rsudo "cd #{current_release} && RAILS_ENV=#{RUBBER_ENV} bundle install --without development test"
256
+ # copied from bundler/capistrano in bundler distro
257
+ bundle_dir = fetch(:bundle_dir, " #{fetch(:shared_path)}/bundle")
258
+ bundle_without = [*fetch(:bundle_without, [:development, :test])].compact
259
+ bundle_flags = fetch(:bundle_flags, "--deployment --quiet")
260
+ bundle_gemfile = fetch(:bundle_gemfile, "Gemfile")
261
+ bundle_cmd = fetch(:bundle_cmd, "bundle")
262
+
263
+ args = ["--gemfile #{fetch(:latest_release)}/#{bundle_gemfile}"]
264
+ args << "--path #{bundle_dir}" unless bundle_dir.to_s.empty?
265
+ args << bundle_flags.to_s
266
+ args << "--without #{bundle_without.join(" ")}" unless bundle_without.empty?
267
+
268
+ rsudo "#{bundle_cmd} install #{args.join(' ')}"
257
269
  end
258
270
 
259
271
  desc <<-DESC
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 1
7
7
  - 5
8
- - 7
9
- version: 1.5.7
8
+ - 8
9
+ version: 1.5.8
10
10
  platform: ruby
11
11
  authors:
12
12
  - Matt Conway
@@ -14,7 +14,7 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2010-07-07 00:00:00 -04:00
17
+ date: 2010-09-01 00:00:00 -04:00
18
18
  default_executable: vulcanize
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency