Fix #3747, #3749

getipaddr() now returns an IP object or throws an error if no external
interfaces are available. Furthermore this also always sets bind-to to
127.0.0.1 for local workers.