1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

libcontainerd/supervisor: use correct logger

Don't call logrus directly, but use the logger that was set.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Sebastiaan van Stijn 2022-08-11 10:41:31 +02:00
parent 2d511f28f2
commit 1d2a669445
No known key found for this signature in database
GPG key ID: 76698F39D527CE8C

View file

@ -161,8 +161,7 @@ func (r *remote) startContainerd() error {
if pid != -1 {
r.daemonPid = pid
logrus.WithField("pid", pid).
Infof("libcontainerd: %s is still running", binaryName)
r.logger.WithField("pid", pid).Infof("%s is still running", binaryName)
return nil
}
@ -210,8 +209,7 @@ func (r *remote) startContainerd() error {
return errors.Wrap(err, "libcontainerd: failed to save daemon pid to disk")
}
logrus.WithField("pid", r.daemonPid).
Infof("libcontainerd: started new %s process", binaryName)
r.logger.WithField("pid", r.daemonPid).Infof("started new %s process", binaryName)
return nil
}
@ -285,7 +283,7 @@ func (r *remote) monitorDaemon(ctx context.Context) {
delay = 100 * time.Millisecond
continue
}
logrus.WithField("address", r.GRPC.Address).Debug("Created containerd monitoring client")
r.logger.WithField("address", r.GRPC.Address).Debug("created containerd monitoring client")
}
if client != nil {