Changes to allow running on Linux

Since socket inheritance doesn't seem possible, this is the next best
thing