Module: Bluepill::Application::ServerMethods

Defined in:
lib/bluepill/application/server.rb

Instance Method Summary collapse

Instance Method Details

#restartObject



10
11
12
13
# File 'lib/bluepill/application/server.rb', line 10

def restart
  self.socket = Bluepill::Socket.new(name, base_dir).client
  socket.send("restart\n", 0)
end

#statusObject



4
5
6
7
8
# File 'lib/bluepill/application/server.rb', line 4

def status
  processes.collect do |process|
    "#{process.name} #{process.state}"
  end.join("\n")
end

#stopObject



15
16
17
18
# File 'lib/bluepill/application/server.rb', line 15

def stop
  self.socket = Bluepill::Socket.new(name, base_dir).client
  socket.send("stop\n", 0)
end