crossroads_capistrano 1.2.5 → 1.2.6

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/README.textile CHANGED
@@ -13,6 +13,6 @@ bc. gem 'crossroads_capistrano', :git => 'http://github.com/crossroads/crossroad
13
13
  Add the following to your project's *config/deploy.rb* :
14
14
 
15
15
  bc. require 'crossroads_capistrano'
16
- CrossroadsCapistrano.load_recipes %w(prompt stack rvm passenger postgresql newrelic log)
16
+ CrossroadsCapistrano.load_recipes %w(prompt rvm stack passenger postgresql newrelic log)
17
17
  # or ..
18
18
  CrossroadsCapistrano.load_recipes :all
@@ -3,7 +3,7 @@ $:.push File.expand_path("../lib", __FILE__)
3
3
 
4
4
  Gem::Specification.new do |s|
5
5
  s.name = "crossroads_capistrano"
6
- s.version = "1.2.5"
6
+ s.version = "1.2.6"
7
7
  s.platform = Gem::Platform::RUBY
8
8
  s.authors = ["Steve Kenworthy", "Ben Tillman", "Nathan Broadbent"]
9
9
  s.email = ["it_dept@crossroads.org.hk"]
@@ -37,10 +37,20 @@ namespace :passenger do
37
37
  yum.install( {:base => %w(curl-devel httpd-devel apr-devel)}, :stable )
38
38
  end
39
39
 
40
- desc "Apache config files"
40
+ desc "Apache config files: uses special variables @DEPLOY_TO@ @IP_ADDR@ @SERVER_NAME@ @PASSENGER_ROOT@ @RUBY_ROOT@"
41
41
  task :config, :roles => :web do
42
42
  run "sed -e 's,@DEPLOY_TO@,#{deploy_to},g' -e 's,@IP_ADDR@,#{ip_address},g' -e 's,@SERVER_NAME@,#{site_domain_name},g' #{release_path}/config/httpd-rails.conf > /etc/httpd/sites-enabled/010-#{application}-#{stage}.conf"
43
- run "sed -e 's,@RVM_RUBY_STRING@,#{rvm_ruby_string},g' -e 's,@PASSENGER_VERSION@,#{passenger_version},g' #{release_path}/config/passenger.conf > /etc/httpd/mods-enabled/passenger.conf"
43
+ passenger_root = ""
44
+ run "pass_path=`gem which phusion_passenger` && echo ${pass_path%/lib/phusion_passenger.rb}" do |channel, stream, data|
45
+ passenger_root = data
46
+ end
47
+ ruby_root = ""
48
+ run "which ruby" do |channel, stream, data|
49
+ ruby_root = data
50
+ end
51
+ sed_args = "-e 's,@PASSENGER_ROOT@,#{passenger_root.strip},g'"
52
+ sed_args << " -e 's,@RUBY_ROOT@,#{ruby_root.strip},g'"
53
+ run "sed #{sed_args} #{release_path}/config/passenger.conf > /etc/httpd/mods-enabled/passenger.conf"
44
54
  end
45
55
 
46
56
  end
@@ -3,13 +3,12 @@ namespace :rvm do
3
3
  desc "Install rvm"
4
4
  task :install, :roles => :web do
5
5
  install_deps
6
-
7
- #~ run "if ! (which rvm); then curl -L http://bit.ly/rvm-install-system-wide | bash; fi"
8
- run "if ! (rvm list | grep #{rvm_ruby_string}); then rvm install #{rvm_ruby_string}; fi"
6
+ run "if ! (which rvm); then curl -s https://rvm.beginrescueend.com/install/rvm | bash; fi", :shell => 'sh'
7
+ run "if ! (rvm list | grep #{rvm_ruby_string}); then rvm install #{rvm_ruby_string}; fi", :shell => 'sh'
9
8
  end
10
9
 
11
10
  task :install_deps, :roles => :web do
12
- yum.install( {:base => %w(curl git gcc-c++ patch readline readline-devel zlib zlib-devel libyaml-devel libffi-devel)}, :stable )
11
+ yum.install( {:base => %w(curl git gcc-c++ patch readline readline-devel zlib zlib-devel libyaml-devel libffi-devel)}, :stable, :shell => 'sh' )
13
12
  end
14
13
 
15
14
  end
metadata CHANGED
@@ -1,8 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: crossroads_capistrano
3
3
  version: !ruby/object:Gem::Version
4
- prerelease:
5
- version: 1.2.5
4
+ hash: 19
5
+ prerelease: false
6
+ segments:
7
+ - 1
8
+ - 2
9
+ - 6
10
+ version: 1.2.6
6
11
  platform: ruby
7
12
  authors:
8
13
  - Steve Kenworthy
@@ -12,7 +17,7 @@ autorequire:
12
17
  bindir: bin
13
18
  cert_chain: []
14
19
 
15
- date: 2011-03-01 00:00:00 +08:00
20
+ date: 2011-04-29 00:00:00 +08:00
16
21
  default_executable:
17
22
  dependencies: []
18
23
 
@@ -57,17 +62,23 @@ required_ruby_version: !ruby/object:Gem::Requirement
57
62
  requirements:
58
63
  - - ">="
59
64
  - !ruby/object:Gem::Version
65
+ hash: 3
66
+ segments:
67
+ - 0
60
68
  version: "0"
61
69
  required_rubygems_version: !ruby/object:Gem::Requirement
62
70
  none: false
63
71
  requirements:
64
72
  - - ">="
65
73
  - !ruby/object:Gem::Version
74
+ hash: 3
75
+ segments:
76
+ - 0
66
77
  version: "0"
67
78
  requirements: []
68
79
 
69
80
  rubyforge_project: crossroads_capistrano
70
- rubygems_version: 1.5.2
81
+ rubygems_version: 1.3.7
71
82
  signing_key:
72
83
  specification_version: 3
73
84
  summary: Crossroads capistrano recipes