Sha256: d628da46baf64fec27fb573bd5ad2de357013efcb55c39c9d113609a2f59b740

Contents?: true

Size: 601 Bytes

Versions: 11

Compression:

Stored size: 601 Bytes

Contents

desc 'run post-deployment stuff'
task :post_deploy do

  # Precompile assets
  puts 'Precompiling assets'
  Rake::Task["assets:precompile"].invoke

  # Run migrations
  puts 'Running migrations if necessary'
  Rake::Task["db:migrate"].invoke

  # Trigger Unicorn reexec with 0 downtime
  puts 'restarting unicorns'
  system "<%= restart_unicorn_command %>"

  # Enable monit monitoring
  puts 'enable monit'
  system "<%= restart_monit_command %>"

  # Notify Airbrake of deployment
  puts 'notifying airbrake'
  system "rake airbrake:deploy TO=#{ENV['RAILS_ENV']} REVISION=$(git rev-parse HEAD)"
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
shoestrap-0.4.1 lib/generators/shoestrap/templates/deployment/deployment.rake.erb
shoestrap-0.4.0 lib/generators/shoestrap/templates/deployment/deployment.rake.erb
shoestrap-0.3.1.pre lib/generators/shoestrap/templates/deployment/deployment.rake.erb
shoestrap-0.3.0 lib/generators/shoestrap/templates/deployment/deployment.rake.erb
shoestrap-0.3.0.pre2 lib/generators/shoestrap/templates/deployment/deployment.rake.erb
shoestrap-0.3.0.pre1 lib/generators/shoestrap/templates/deployment/deployment.rake.erb
shoestrap-0.3.0.pre lib/generators/shoestrap/templates/deployment/deployment.rake.erb
shoestrap-0.2.5 lib/generators/shoestrap/templates/deployment/deployment.rake.erb
shoestrap-0.2.4 lib/generators/shoestrap/templates/deployment/deployment.rake.erb
shoestrap-0.2.3 lib/generators/shoestrap/templates/deployment/deployment.rake.erb
shoestrap-0.2.2 lib/generators/shoestrap/templates/deployment/deployment.rake.erb