Auth: Set address

This commit is contained in:
Ben Toogood
2020-05-13 17:54:47 +01:00
parent ebd53794af
commit 366fb228e5
2 changed files with 37 additions and 22 deletions

View File

@@ -44,10 +44,19 @@ type Options struct {
Store store.Store
// Client to use for RPC
Client client.Client
// Addrs sets the addresses of auth
Addrs []string
}
type Option func(o *Options)
// Addrs is the auth addresses to use
func Addrs(addrs ...string) Option {
return func(o *Options) {
o.Addrs = addrs
}
}
// Namespace the service belongs to
func Namespace(n string) Option {
return func(o *Options) {