diff --git a/servercfg/serverconf.go b/servercfg/serverconf.go index 58d8b601..aa78fb85 100644 --- a/servercfg/serverconf.go +++ b/servercfg/serverconf.go @@ -236,6 +236,11 @@ func GetMessageQueueEndpoint() (string, bool) { host = config.Config.Server.MQHOST } secure := strings.Contains(host, "wss") || strings.Contains(host, "ssl") + if secure { + host = "wss://" + host + } else { + host = "ws://" + host + } return host + ":" + GetMQServerPort(), secure }