youthtree-capistrano 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,6 +1,6 @@
1
1
  module YouthTree
2
2
  module Capistrano
3
- VERSION = "0.1.1".freeze
3
+ VERSION = "0.1.2".freeze
4
4
 
5
5
  def self.load(&blk)
6
6
  ::Capistrano::Configuration.instance(:must_exist).load(&blk)
@@ -1,5 +1,6 @@
1
1
  YouthTree::Capistrano.load_named(:unicorn) do
2
2
 
3
+ yt_cset :unicorn_app_type, 'rack'
3
4
  yt_cset :unicorn_shared_config, 'unicorn.rb'
4
5
  yt_cset :unicorn_latest_config, 'config/unicorn.rb'
5
6
  yt_cset :unicorn_pid_file, 'tmp/pids'
@@ -23,7 +24,12 @@ YouthTree::Capistrano.load_named(:unicorn) do
23
24
 
24
25
  desc "Starts the unicorn app server"
25
26
  task :start, :roles => :app do
26
- run "cd '#{current_path}' && bundle exec unicorn_rails -D -E #{rails_env} -c '#{current_path}/#{unicorn_latest_config}'"
27
+ if unicorn_app_type.to_s == "rails"
28
+ command = "unicorn_rails -D -E #{rails_env} -c '#{current_path}/#{unicorn_latest_config}'"
29
+ else
30
+ command = "unicorn -D -E #{rails_env} -c '#{current_path}/#{unicorn_latest_config}' config.ru"
31
+ end
32
+ run "cd '#{current_path}' && bundle exec "
27
33
  end
28
34
 
29
35
  desc "Stops the unicorn app server"
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{youthtree-capistrano}
8
- s.version = "0.1.1"
8
+ s.version = "0.1.2"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Darcy Laycock"]
12
- s.date = %q{2010-08-27}
12
+ s.date = %q{2010-08-28}
13
13
  s.description = %q{Capistrano tasks used for common Youth Tree deployments.}
14
14
  s.email = %q{sutto@sutto.net}
15
15
  s.extra_rdoc_files = [
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: youthtree-capistrano
3
3
  version: !ruby/object:Gem::Version
4
- hash: 25
4
+ hash: 31
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 1
9
- - 1
10
- version: 0.1.1
9
+ - 2
10
+ version: 0.1.2
11
11
  platform: ruby
12
12
  authors:
13
13
  - Darcy Laycock
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2010-08-27 00:00:00 +08:00
18
+ date: 2010-08-28 00:00:00 +08:00
19
19
  default_executable:
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency