Project

mina-faye

0.0
No commit activity in last 3 years
No release in over 3 years
Adds tasks to aid in the deployment of Faye
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Runtime

>= 0
 Project Readme

mina-faye

mina-faye is a gem that adds tasks to help the deployment of Faye using [Mina] (http://nadarei.co/mina). This gem based on [mina-sidekiq gem] (https://github.com/Mic92/mina-sidekiq) by [Mic92] (https://github.com/Mic92)

Getting Start

Installation

gem install mina-faye

Example

Usage example

require 'mina_faye/tasks'
...
# to make logs persistent between deploys
set :faye_config, "faye.ru"

task :setup do
  # faye needs a place to store its pid file
  queue! %[mkdir -p "#{deploy_to}/shared/pids/"]
end

task :deploy do
  deploy do
    # stop accepting new workers
    invoke :'git:clone'
    invoke :'deploy:link_shared_paths'
    ...

    to :launch do
      ...
      invoke :'faye:restart'
    end
  end
end

Available Tasks

  • faye:stop
  • faye:start
  • faye:restart

Available Options

Option Description
faye_config Sets the path to faye config file.
faye_pid Sets the path to the pid file of a faye server.

Testing

The test requires a local running ssh server with the ssh keys of the current user added to its ~/.ssh/authorized_keys. In OS X, this is "Remote Login" under the Sharing pref pane.

To run the full blown test suite use:

bundle exec rake test

For faster release cycle use

cd test_env
bundle exec mina deploy --verbose