mirror of
https://github.com/status-im/consul.git
synced 2025-01-14 07:44:50 +00:00
docker: stop previous check on replace
This commit is contained in:
parent
e774b46f82
commit
164ec3ec39
@ -1776,6 +1776,9 @@ func (a *Agent) AddCheck(check *structs.HealthCheck, chkType *structs.CheckType,
|
|||||||
Logger: a.logger,
|
Logger: a.logger,
|
||||||
Client: a.dockerClient,
|
Client: a.dockerClient,
|
||||||
}
|
}
|
||||||
|
if prev := a.checkDockers[check.CheckID]; prev != nil {
|
||||||
|
prev.Stop()
|
||||||
|
}
|
||||||
dockerCheck.Start()
|
dockerCheck.Start()
|
||||||
a.checkDockers[check.CheckID] = dockerCheck
|
a.checkDockers[check.CheckID] = dockerCheck
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user