Sha256: ed7d948bd50c2bc12ffce5ac7de00152bca9ddaecfc1f906243dfd3e6bb828cf

Contents?: true

Size: 1.25 KB

Versions: 24

Compression:

Stored size: 1.25 KB

Contents

Capistrano::Configuration.instance(:must_exist).load do

  namespace :nginx do 
    desc "Start Nginx on the app slices."
    task :start, :roles => :app do
      sudo "nohup /etc/init.d/nginx start 2>&1 | cat"
    end

    desc "Restart the Nginx processes on the app slices."
    task :restart , :roles => :app do
      sudo "nohup /etc/init.d/nginx restart 2>&1 | cat"
    end

    desc "Stop the Nginx processes on the app slices."
    task :stop , :roles => :app do
      sudo "/etc/init.d/nginx stop"
    end
    
    desc "Reload the Nginx config on the app slices."
    task :reload , :roles => :app do
      sudo "/etc/init.d/nginx reload"
    end

    desc "Upgrade the Nginx processes on the app slices."
    task :upgrade , :roles => :app do
      sudo "/etc/init.d/nginx upgrade"
    end

    desc "Test the Nginx config on the app slices."
    task :configtest , :roles => :app do
      sudo "/etc/init.d/nginx configtest"
    end

    desc "Tail the nginx error logs on the app slices"
    task :tail_error, :roles => :app do
      run "tail -f /var/log/engineyard/nginx/error.log" do |channel, stream, data|
        puts "#{channel[:server]}: #{data}" unless data =~ /^10\.[01]\.0/ # skips lb pull pages
        break if stream == :err    
      end
    end

  end
end

Version data entries

24 entries across 24 versions & 4 rubygems

Version Path
engineyard-eycap-0.4.14 lib/eycap/recipes/nginx.rb
engineyard-eycap-0.4.15 lib/eycap/recipes/nginx.rb
eycap-0.5.19 lib/eycap/recipes/nginx.rb
eycap-0.5.18 lib/eycap/recipes/nginx.rb
eycap-0.5.17 lib/eycap/recipes/nginx.rb
eycap-0.5.16 lib/eycap/recipes/nginx.rb
eycap-0.5.15 lib/eycap/recipes/nginx.rb
eycap-0.5.14 lib/eycap/recipes/nginx.rb
eycap-0.5.13 lib/eycap/recipes/nginx.rb
eycap-0.5.12 lib/eycap/recipes/nginx.rb
eycap-0.5.11 lib/eycap/recipes/nginx.rb
eycap-0.5.10 lib/eycap/recipes/nginx.rb
eycap-0.5.9 lib/eycap/recipes/nginx.rb
eycap-0.5.8 lib/eycap/recipes/nginx.rb
eycap-0.5.7 lib/eycap/recipes/nginx.rb
newrelic-eycap-0.5.6.0 lib/eycap/recipes/nginx.rb
eycap-0.5.6 lib/eycap/recipes/nginx.rb
gabetax-eycap-0.5.6 lib/eycap/recipes/nginx.rb
eycap-0.5.5 lib/eycap/recipes/nginx.rb
eycap-0.5.3 lib/eycap/recipes/nginx.rb