add after_push
add before_restart

assume db:migrate and asset_pipeline
add post-receive

copy to .git/hooks
Merge branch 'deploy'