Sha256: f2cc76b2bc35dd67937f22ddf5e709d248861a80a65405c0e07293f598cbfd1b

Contents?: true

Size: 1.01 KB

Versions: 8

Compression:

Stored size: 1.01 KB

Contents

namespace :backgroundrb do
  
  namespace :centos do
    
    desc <<-DESC
    Setup backgroundrb for application.
    
    <dl>
    <dt>backgroundrb_bin_path</dt>
    <dd>Path to start.
    <dd class="default">Defaults to @\#{current_path}/script/backgroundrb -e production start@</dd>
    <dt>backgroundrb_pid_path</dt>
    <dd>Path to backgroundrb pid file</dd>
    <dd class="default">Defaults to @\#{shared_path}/pids/backgroundrb.pid@</dd>
    </dl>
    "Source":#{link_to_source(__FILE__)}
    DESC
    task :setup do       
      
      # Settings
      fetch_or_default(:backgroundrb_bin_path, "#{current_path}/script/backgroundrb -e production start")
      fetch_or_default(:backgroundrb_pid_path, "#{shared_path}/pids/backgroundrb.pid")

      # Install initscript      
      utils.install_template("backgroundrb/backgroundrb.initd.centos.erb", "/etc/init.d/backgroundrb_#{application}")

      # Enable service
      run_via "/sbin/chkconfig --level 345 backgroundrb_#{application} on"    
      
    end
    
  end
  
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
capitate-0.2.15 lib/recipes/centos/backgroundrb.rb
capitate-0.2.13 lib/recipes/centos/backgroundrb.rb
capitate-0.2.14 lib/recipes/centos/backgroundrb.rb
capitate-0.3.2 lib/recipes/centos/backgroundrb.rb
capitate-0.3.1 lib/recipes/centos/backgroundrb.rb
capitate-0.3.4 lib/recipes/centos/backgroundrb.rb
capitate-0.3.3 lib/recipes/centos/backgroundrb.rb
capitate-0.3.5 lib/recipes/centos/backgroundrb.rb