Skip to content

Commit

Permalink
Several fixes in capistrano recipe
Browse files Browse the repository at this point in the history
 * Switch to ruby 2.1
 * Avoid sync with static.o.o (not used since some time ago)
 * Use rake.ruby instead of plain rake
  • Loading branch information
ancorgs committed Mar 11, 2014
1 parent bea89bb commit c850e97
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions config/deploy.rb
Expand Up @@ -38,14 +38,14 @@
set :runner, "root"

after "deploy:update_code", "config:symlink_shared_config"
after "deploy:update_code", "config:sync_static"
#after "deploy:update_code", "config:sync_static"
after "deploy:create_symlink", "config:permissions"
after "deploy:restart", "deploy:notify"

set :keep_releases, 5
after 'deploy:update', 'deploy:cleanup' # only keep 5 releases

io = IO.popen('BUNDLE_FROZEN=1 BUNDLE_WITHOUT=test:development bundle show --paths | sed -e "s,.*/,,; s,^,rubygem(2.0.0:,; s,-\([^-]*\)$,) = \1,"')
io = IO.popen('BUNDLE_FROZEN=1 BUNDLE_WITHOUT=test:development bundle show --paths | sed -e "s,.*/,,; s,^,rubygem(2.1.0:,; s,-\([^-]*\)$,) = \1,"')
zypperlines = io.readlines

begin
Expand All @@ -70,7 +70,7 @@
run "cd #{release_path}; zypper -n in -C \"#{zypperlines.join('" "')}\""
run "cd #{release_path}; bundle config --local frozen 1; bundle config --local without test:development"
run "cd #{release_path}; bundle show"
run "cd #{release_path}; bundle exec rake assets:precompile RAILS_ENV=production --trace"
run "cd #{release_path}; bundle exec rake.ruby assets:precompile RAILS_ENV=production --trace"
end

desc "Set permissions"
Expand Down

0 comments on commit c850e97

Please sign in to comment.