Added support for custom host and port