title: Check if process is running, if not start it
body: <p>I'm using Ratchet, a Node js application and ZeroMq in my codeigniter based php application.</p>
  
  <p>In my admin dashboard, I want to be able to see if the socket is running and also if my node js app is running. If it's down, I need to be able to put it back online.</p>
  
  <p>I know I can use php's <code>exec</code> for putting it back online, but as soon as the script finish, so does the command line.</p>
  
  <p>How can I achieve this? Something like:</p>
  
  <p>Ratchet: Status online (Stop, Start, Restart)
  Node service: Status online (Stop, Start, Restart)
  ZeroMq: Status online (Stop, Start, Restart)</p>