Mina tasks for handle with Unicorn
This gem provides several mina tasks:
mina unicorn:start # Start unicorn
mina unicorn:stop # Stop unicorn
mina unicorn:restart # Restart unicorn (with zero-downtime)
Add this line to your application's Gemfile:
gem 'mina-unicorn', :require => false
And then execute:
$ bundle
Or install it yourself as:
$ gem install mina-unicorn
Add this to your config/deploy.rb
file:
require 'mina/unicorn'
Make sure the following settings are set in your config/deploy.rb
:
deploy_to
- deployment path
Make sure the following directories exists on your server:
shared/tmp/sockets
- directory for socket files.shared/tmp/pids
- direcotry for pid files.
OR you can set other directories by setting follow variables:
unicorn_role
- unicorn userunicorn_env
- set environmentunicorn_config
- unicorn config fileunicorn_cmd
- bundle exec unicornunicorn_pid
- unicorn pid file, defaultshared/tmp/pids/unicorn.pid
Then:
$ mina unicorn:start
- Fork it ( http://github.com/openteam/mina-unicorn/fork )
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request