Added a pid file option so that it can be more easily made a daemon