Commit 07477ab
Changed files (2)
config
config/deploy.rb
@@ -45,11 +45,7 @@ set :linked_dirs, fetch(:linked_dirs, []).push(
# Default value for keep_releases is 5
# set :keep_releases, 5
-if File.exist?("config/deploy_id_rsa")
- set :ssh_options, keys: ["config/deploy_id_rsa"]
-else
- set :ssh_options, forward_agent: true
-end
+set :ssh_options, forward_agent: true
set :rbenv_type, :system
set :rbenv_ruby, "2.2.2"
.travis.yml
@@ -8,7 +8,11 @@ before_script:
- cp config/database.yml.travis config/database.yml
- psql -c 'create database app_test;' -U postgres
after_success:
-- openssl aes-256-cbc -k $DEPLOY_KEY -in config/deploy_id_rsa_enc_travis -d -a -out config/deploy_id_rsa
+- openssl aes-256-cbc -k $DEPLOY_KEY -in config/deploy_id_rsa_enc_travis -d -a -out ~/.ssh/id_rsa
+- chmod 600 ~/.ssh/id_rsa
+- echo -e "Host www.stronglifters.com\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config
+- eval "$(ssh-agent)"
+- ssh-add
- [[ $TRAVIS_BRANCH = 'master' ]] && bundle exec cap production deploy
env:
global: