title: Kohana -- Command Line
body: <p>I'm trying to "faux-fork" a process (an email being sent via SMTP) in my web application, and the application is built on Kohana.  </p>
  
  <pre><code>    $command = 'test/email';
      exec('php index.php '.$command.' &gt; /dev/null/ &amp;', $errors, $response);
  </code></pre>
  
  <p>I'm getting an error --</p>
  
  <p><code>Notice: Undefined index: SERVER_NAME</code></p>
  
  <p>When I look into Kohana's index.php file, I see that it is looking for a variable named SERVER_NAME, but I guess it is coming up NULL because Kohana couldn't detect this value and set it prior to run.</p>
  
  <p>Any ideas how to get Kohana to run via command line?</p>