title: Get Rails base URL if not in controller
body: <p>In controller a base URL could be got using <code>request</code> object, but my process is a worker thread started from initializer, and it doesn't have access to <code>request</code>.</p>