Don't fork to hostname, use Socket.gethostname.