daemon: Daemon.killWithSignal(): don't discard snapshotting errors
While there's not much we can do if we failed to store a snapshot of the container's state, let's log the error in case it happens in stad of discarding. Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
parent
af535233cc
commit
b9f9e20f01
1 changed files with 6 additions and 1 deletions
|
@ -87,7 +87,12 @@ func (daemon *Daemon) killWithSignal(container *containerpkg.Container, stopSign
|
|||
|
||||
if !daemon.IsShuttingDown() {
|
||||
container.HasBeenManuallyStopped = true
|
||||
container.CheckpointTo(daemon.containersReplica)
|
||||
if err := container.CheckpointTo(daemon.containersReplica); err != nil {
|
||||
log.G(context.TODO()).WithFields(log.Fields{
|
||||
"error": err,
|
||||
"container": container.ID,
|
||||
}).Warn("error checkpointing container state")
|
||||
}
|
||||
}
|
||||
|
||||
// if the container is currently restarting we do not need to send the signal
|
||||
|
|
Loading…
Add table
Reference in a new issue