changed socket host to depend on host