Skip to content

Commit

Permalink
Further work on capistrano staging-evironment
Browse files Browse the repository at this point in the history
  • Loading branch information
philippbayer committed Oct 5, 2012
1 parent 7c0b31c commit bd6bb45
Show file tree
Hide file tree
Showing 4 changed files with 50 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Capfile
Original file line number Original file line Diff line number Diff line change
@@ -0,0 +1,4 @@
load 'deploy'
# Uncomment if you are using Rails' asset pipeline
# load 'deploy/assets'
load 'config/deploy' # remove this line to skip loading any of the default tasks
1 change: 1 addition & 0 deletions Gemfile
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ gem 'bartt-ssl_requirement', '~>1.4.0', :require => 'ssl_requirement'
gem 'vegas' gem 'vegas'
gem 'bcrypt-ruby', :require => "bcrypt" gem 'bcrypt-ruby', :require => "bcrypt"
gem 'fitgem' gem 'fitgem'
gem 'rvm-capistrano'


# Bundle edge Rails instead: # Bundle edge Rails instead:
# gem 'rails', :git => 'git://github.com/rails/rails.git' # gem 'rails', :git => 'git://github.com/rails/rails.git'
Expand Down
19 changes: 19 additions & 0 deletions Gemfile.lock
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -60,6 +60,12 @@ GEM
bartt-ssl_requirement (1.4.2) bartt-ssl_requirement (1.4.2)
bcrypt-ruby (3.0.1) bcrypt-ruby (3.0.1)
builder (2.1.2) builder (2.1.2)
capistrano (2.13.4)
highline
net-scp (>= 1.0.0)
net-sftp (>= 2.0.0)
net-ssh (>= 2.0.14)
net-ssh-gateway (>= 1.1.0)
cocaine (0.3.0) cocaine (0.3.0)
columnize (0.3.6) columnize (0.3.6)
erubis (2.6.6) erubis (2.6.6)
Expand All @@ -69,10 +75,12 @@ GEM
activesupport (>= 3.0.0) activesupport (>= 3.0.0)
fitgem (0.5.2) fitgem (0.5.2)
oauth oauth
highline (1.6.15)
i18n (0.5.0) i18n (0.5.0)
jquery-rails (1.0.19) jquery-rails (1.0.19)
railties (~> 3.0) railties (~> 3.0)
thor (~> 0.14) thor (~> 0.14)
jruby-pageant (1.1.1)
json (1.7.5) json (1.7.5)
linecache19 (0.5.12) linecache19 (0.5.12)
ruby_core_source (>= 0.1.4) ruby_core_source (>= 0.1.4)
Expand All @@ -90,6 +98,14 @@ GEM
mocha (0.12.3) mocha (0.12.3)
metaclass (~> 0.0.1) metaclass (~> 0.0.1)
multi_json (1.3.6) multi_json (1.3.6)
net-scp (1.0.4)
net-ssh (>= 1.99.1)
net-sftp (2.0.5)
net-ssh (>= 2.0.9)
net-ssh (2.6.0)
jruby-pageant (>= 1.1.1)
net-ssh-gateway (1.1.0)
net-ssh (>= 1.99.1)
nokogiri (1.5.5) nokogiri (1.5.5)
oauth (0.4.6) oauth (0.4.6)
paperclip (2.7.0) paperclip (2.7.0)
Expand Down Expand Up @@ -149,6 +165,8 @@ GEM
ruby_core_source (0.1.5) ruby_core_source (0.1.5)
archive-tar-minitar (>= 0.5.2) archive-tar-minitar (>= 0.5.2)
rubyzip (0.9.5) rubyzip (0.9.5)
rvm-capistrano (1.2.7)
capistrano (>= 2.0.0)
shoulda-context (1.0.0) shoulda-context (1.0.0)
shoulda-matchers (1.3.0) shoulda-matchers (1.3.0)
activesupport (>= 3.0.0) activesupport (>= 3.0.0)
Expand Down Expand Up @@ -202,6 +220,7 @@ DEPENDENCIES
resque-loner resque-loner
ruby-debug19 ruby-debug19
rubyzip (= 0.9.5) rubyzip (= 0.9.5)
rvm-capistrano
shoulda-context shoulda-context
shoulda-matchers shoulda-matchers
sunspot_rails (~> 1.2.1) sunspot_rails (~> 1.2.1)
Expand Down
26 changes: 26 additions & 0 deletions config/deploy.rb
Original file line number Original file line Diff line number Diff line change
@@ -0,0 +1,26 @@
require 'capistrano/ext/multistage'
set :stages, %w(production staging)
set :default_stage, "staging"

set :application, "snpr"
set :repository, "set your repository location here"

set :scm, :git
# Or: `accurev`, `bzr`, `cvs`, `darcs`, `git`, `mercurial`, `perforce`, `subversion` or `none`
#
set :repository, "https://github.com/gedankenstuecke/snpr.git"
set :deploy_to, "/var/www/snpr"
set :deploy_via, :remote_cache
set :rails_env, "production"

# if you're still using the script/reaper helper you will need
# these http://github.com/rails/irs_process_scripts

# If you are using Passenger mod_rails uncomment this:
# namespace :deploy do
# task :start do ; end
# task :stop do ; end
# task :restart, :roles => :app, :except => { :no_release => true } do
# run "#{try_sudo} touch #{File.join(current_path,'tmp','restart.txt')}"
# end
# end

0 comments on commit bd6bb45

Please sign in to comment.