Hostname config

Allow the hostname to be set via env and then config. Useful for binding to locahost and then using a proxy