Merge pull request #14 from LK4D4/add_logging
Add logging and more info
This commit is contained in:
@@ -103,6 +103,9 @@ func daemon(id, stateDir string, concurrency, bufferSize int) error {
|
||||
}
|
||||
// only set containerd as the subreaper if it is not an init process
|
||||
if pid := os.Getpid(); pid != 1 {
|
||||
logrus.WithFields(logrus.Fields{
|
||||
"pid": pid,
|
||||
}).Debug("containerd is not init, set as subreaper")
|
||||
if err := setSubReaper(); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
@@ -14,7 +14,9 @@ import (
|
||||
)
|
||||
|
||||
func startSignalHandler(supervisor *containerd.Supervisor, bufferSize int) {
|
||||
logrus.Debug("containerd: starting signal handler")
|
||||
logrus.WithFields(logrus.Fields{
|
||||
"bufferSize": bufferSize,
|
||||
}).Debug("containerd: starting signal handler")
|
||||
signals := make(chan os.Signal, bufferSize)
|
||||
signal.Notify(signals)
|
||||
for s := range signals {
|
||||
|
||||
Reference in New Issue
Block a user