Skip to content

Commit 7ea6a67

Browse files
committed
Ensure health probe is stopped when a container exits
Signed-off-by: Antonio Murdaca <runcom@redhat.com>
1 parent 0bb67bd commit 7ea6a67

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

daemon/monitor.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,9 @@ func (daemon *Daemon) StateChanged(id string, e libcontainerd.StateInfo) error {
4545
defer daemon.autoRemove(c)
4646
}
4747

48-
daemon.updateHealthMonitor(c)
48+
// cancel healthcheck here, they will be automatically
49+
// restarted if/when the container is started again
50+
daemon.stopHealthchecks(c)
4951
attributes := map[string]string{
5052
"exitCode": strconv.Itoa(int(e.ExitCode)),
5153
}

0 commit comments

Comments
 (0)