title: How can I boot Rails 3 in a daemonized ruby script?
body: <p>I am pulling email via pop into my Rails 3 application so i have a file called dropbox_receiver.rb in the rails lib directory.   </p>
  
  <p>This pulls in all email and calls DropBox.receive(email)</p>
  
  <p>I can run this using rails/runner but when i run it from the daemon_controller.rb file i get the error </p>
  
  <pre><code>initialized constant Object::DropBox
  </code></pre>
  
  <p>How do i boot rails 3 in this script ?</p>
  
  <p>Also how do i log properly from this script to my production.log?</p>