diff options
Diffstat (limited to 'config/deploy.rb')
| -rw-r--r-- | config/deploy.rb | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/config/deploy.rb b/config/deploy.rb new file mode 100644 index 0000000..7d762c2 --- /dev/null +++ b/config/deploy.rb @@ -0,0 +1,48 @@ +require "bundler/capistrano" +require "rvm/capistrano" + +load "config/recipes/base" +load "config/recipes/nginx" +load "config/recipes/unicorn" +load "config/recipes/postgresql" +load "config/recipes/nodejs" +load "config/recipes/rvm" +load "config/recipes/check" + +# Your HTTP server, Apache/etc +role :web, "www.parleytool.com" +# This may be the same as your `Web` server +role :app, "www.parleytool.com" +# This is where Rails migrations will run +role :db, "www.parleytool.com", primary: true +#role :db, "your slave db-server here" + +set :application, "parley" +set :user, "demo" +set :deploy_to, "/home/#{user}/apps/#{application}" +set :deploy_via, :remote_cache # keeps git repo on server cache +set :use_sudo, false + +set :scm, "git" +set :branch, "master" +set :repository, "git@github.com:madebyuppercut/parley.git" + +set :rvm_ruby_string, :local # use the same ruby as used locally for deployment + +default_run_options[:pty] = true # password prompt +ssh_options[:forward_agent] = true # no deploy key for github + +before 'deploy:setup', 'rvm:install_rvm' # update RVM +before 'deploy:setup', 'rvm:install_ruby' # install Ruby and create gemset (both if missing) + +after "deploy", "deploy:cleanup" # keep only the last 5 releases + +# Instructions +############## +# ssh root@198.199.101.128 +# adduser deployer --ingroup admin +# exit +# cap deploy:install +# cap deploy:setup +# cap deploy:cold +# cap nginx:start # this may be necessary if it didn't start up properly before |
