test: allocate ports in blocks of 10
This commit is contained in:
parent
26474ce9c2
commit
e8651261f9
|
@ -224,7 +224,7 @@ func (a *TestAgent) consulConfig() *consul.Config {
|
|||
// Instead of relying on one set of ports to be sufficient we retry
|
||||
// starting the agent with different ports on port conflict.
|
||||
func pickRandomPorts(c *Config) {
|
||||
port := 1030 + int(rand.Int31n(64400))
|
||||
port := 1030 + int(rand.Int31n(6440))*10
|
||||
c.Ports.DNS = port + 1
|
||||
c.Ports.HTTP = port + 2
|
||||
c.Ports.HTTPS = port + 3
|
||||
|
|
Loading…
Reference in New Issue