mirror of
https://github.com/Luzifer/mqttcli.git
synced 2024-11-08 14:50:11 +00:00
Fix: Set client id
Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
parent
46ed69eff1
commit
5117cc2519
1 changed files with 1 additions and 0 deletions
1
main.go
1
main.go
|
@ -67,6 +67,7 @@ func main() {
|
||||||
client := mqtt.NewClient(
|
client := mqtt.NewClient(
|
||||||
mqtt.NewClientOptions().
|
mqtt.NewClientOptions().
|
||||||
AddBroker(cfg.MQTTBroker).
|
AddBroker(cfg.MQTTBroker).
|
||||||
|
SetClientID(cfg.MQTTClientID).
|
||||||
SetUsername(cfg.MQTTUser).
|
SetUsername(cfg.MQTTUser).
|
||||||
SetPassword(cfg.MQTTPass),
|
SetPassword(cfg.MQTTPass),
|
||||||
)
|
)
|
||||||
|
|
Loading…
Reference in a new issue