Class: Configure::Controllers::Kill

### Home Classes Methods

### In Files

- lib/mongrel_config/app.rb

### Parent

R'/kill/(\w+)'

### Methods

- #get

### Class/Module Index

Quicksearch

- Configure
- Configure::Controllers
- Configure::Controllers::ClearLogs
- Configure::Controllers::Delete
- Configure::Controllers::Index
- Configure::Controllers::Info
- Configure::Controllers::Install
- Configure::Controllers::Kill
- Configure::Controllers::Logs
- Configure::Controllers::Start
- Configure::Controllers::Stop
- Configure::Views
- ConfigTool
- W32Support

No matching classes.

# Configure::Controllers::Kill

### Public Instance Methods

get(signal) click to toggle source

    # File lib/mongrel_config/app.rb, line 28
    def get(signal)
      if _running?
        @signal = signal.upcase
        pid = open($PID_FILE) {|f| f.read }
        begin
          Process.kill(@signal, pid.to_i)
          @results = "Mongrel sent PID #{pid} signal #{@signal}."
        rescue
          puts "ERROR: #$!"
          @results = "Failed to signal the Mongrel process.  Maybe it is not running?<p>#$!</p>"
        end
      else
        @results = "Mongrel does not seem to be running.  Maybe delete the pid file #{$PID_FILE} or start again."
      end

      render :kill
    end

[Validate]

Generated with the Darkfish Rdoc Generator 2.