Sha256: bc73d8b057d86081aff5c5028f802a405558dfc6a3a912cbbaebf55dcaca5a36

Contents?: true

Size: 1.08 KB

Versions: 1

Compression:

Stored size: 1.08 KB

Contents

# Pushapp Configuration File
require 'pushapp/tasks/upstart'
require 'pushapp/tasks/nginx_export'
require 'pushapp/tasks/foreman_export'
require 'pushapp/tasks/unicorn_restart'

# Sample remote definition:
#
#   remote <remote_name>, <app_location>, [options]
#
# The options provided in the target definition will override any
# options provided in the task call.
#
# You can specify multiple remotes in groups
#
# group(:production, env: {RAILS_ENV: 'production'})do
#   remote :web, 'app@server1:/home/app/app',
#     web: true, db: true
#
#   remote :worker, 'app@server2:/home/app/app',
#     worker: true
# end

remote 'production', 'app@server3:/home/app/app',
  upstart_jobs: ['worker']
  env: {RAILS_ENV: 'production'}

on :setup do
  task :nginx_export
  rake('db:create db:migrate db:seed')
  rake('assets:precompile', env: {RAILS_GROUP: :assets})
  task(:foreman_export)
end

on :push do
  rake('db:migrate')
  rake('assets:precompile', env: {RAILS_GROUP: :assets})
  task(:upstart_restart) # restarting options[:upstart_jobs]
  task(:unicorn_restart)  # sending USR2 signal to unicorn
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
pushapp-0.0.5 templates/config.rb.erb