Permalink
Browse files

Add Capistrano config

  • Loading branch information...
1 parent 707397d commit 3f0638b4f089be6b0341c46607e48c478aef2111 @jeffkreeftmeijer jeffkreeftmeijer committed Jun 15, 2011
Showing with 39 additions and 0 deletions.
  1. +4 −0 Capfile
  2. +35 −0 config/deploy.rb
View
@@ -0,0 +1,4 @@
+load 'deploy' if respond_to?(:namespace) # cap2 differentiator
+Dir['vendor/gems/*/recipes/*.rb','vendor/plugins/*/recipes/*.rb'].each { |plugin| load(plugin) }
+
+load 'config/deploy' # remove this line to skip loading any of the default tasks
View
@@ -0,0 +1,35 @@
+$:.unshift(File.expand_path('./lib', ENV['rvm_path']))
+require "rvm/capistrano"
+require 'bundler/capistrano'
+
+set :application, "codebrawl"
+set :repository, "git@github.com:jeffkreeftmeijer/codebrawl.git"
+
+set :scm, :git
+set :branch, "develop"
+set :ssh_options, { :forward_agent => true }
+
+role :web, "204.62.15.57"
+role :app, "204.62.15.57"
+set :user, "codebrawl"
+set :use_sudo, false
+set :deploy_to, "/home/codebrawl"
+set :rvm_ruby_string, 'ruby-1.9.2'
+
+default_run_options[:pty] = true
+
+namespace :deploy do
+ task :start, :roles => :app do
+ run "touch #{current_release}/tmp/restart.txt"
+ end
+
+ task :stop, :roles => :app do
+ # Do nothing.
+ end
+
+ desc 'Restart Application'
+ task :restart, :roles => :app do
+ run "touch #{current_release}/tmp/restart.txt"
+ end
+
+end

0 comments on commit 3f0638b

Please sign in to comment.