moleculer-go / moleculer

🚀 Progressive microservices framework for Go - based and compatible with https://github.com/moleculerjs/moleculer

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

authorization options for NATS transport

vpashka opened this issue · comments

Hello,

nats.Options have User, Password (Token, TLSConfig etc).
How can I transfer authorization parameters when creating a broker?

	var brk = broker.New(&moleculer.Config{
                ...
		Transporter:        "nats://localhost:6222",
	})

I think I found the answer myself

Transporter:        "nats://user:pass@localhost:4222",