mirror of
https://github.com/gravitl/netmaker.git
synced 2025-10-07 09:41:37 +08:00
add : in server connection string
This commit is contained in:
@@ -210,7 +210,7 @@ func NewTLSConfig(server string) *tls.Config {
|
|||||||
func setupMQTT(cfg *config.ClientConfig, publish bool) (mqtt.Client, error) {
|
func setupMQTT(cfg *config.ClientConfig, publish bool) (mqtt.Client, error) {
|
||||||
opts := mqtt.NewClientOptions()
|
opts := mqtt.NewClientOptions()
|
||||||
server := cfg.Server.Server
|
server := cfg.Server.Server
|
||||||
opts.AddBroker("ssl://" + server + servercfg.GetMQPort())
|
opts.AddBroker("ssl://" + server + ":" + servercfg.GetMQPort())
|
||||||
opts.SetTLSConfig(NewTLSConfig(server))
|
opts.SetTLSConfig(NewTLSConfig(server))
|
||||||
opts.SetClientID(ncutils.MakeRandomString(23))
|
opts.SetClientID(ncutils.MakeRandomString(23))
|
||||||
opts.SetDefaultPublishHandler(All)
|
opts.SetDefaultPublishHandler(All)
|
||||||
|
@@ -224,8 +224,7 @@ func GetMessageQueueEndpoint() string {
|
|||||||
} else if config.Config.Server.MQHOST != "" {
|
} else if config.Config.Server.MQHOST != "" {
|
||||||
host = config.Config.Server.MQHOST
|
host = config.Config.Server.MQHOST
|
||||||
}
|
}
|
||||||
//Do we want MQ port configurable???
|
return host + ":" + GetMQServerPort()
|
||||||
return host + GetMQServerPort()
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// GetMasterKey - gets the configured master key of server
|
// GetMasterKey - gets the configured master key of server
|
||||||
|
Reference in New Issue
Block a user