mirror of https://github.com/hashicorp/consul
Return error if ServerAddresses is empty (#13714)
parent
123047d5b5
commit
a6634db4a5
|
@ -70,6 +70,9 @@ func (b *PeeringBackend) GetServerAddresses() ([]string, error) {
|
|||
}
|
||||
addrs = append(addrs, node.Address+":"+grpcPortStr)
|
||||
}
|
||||
if len(addrs) == 0 {
|
||||
return nil, fmt.Errorf("a grpc bind port must be specified in the configuration for all servers")
|
||||
}
|
||||
return addrs, nil
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue