From 024568f3cecfbdde04bfabe533be328b763ac0da Mon Sep 17 00:00:00 2001 From: Samuel Ortiz Date: Wed, 17 Jan 2018 16:55:46 +0100 Subject: [PATCH] main: Set the OCI vc package logger In order to merge the virtcontainers OCI package logs with the rest of the cc-runtime ones. Fixes #934 Signed-off-by: Samuel Ortiz --- main.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/main.go b/main.go index 3049e502..0e4ea56b 100644 --- a/main.go +++ b/main.go @@ -23,6 +23,7 @@ import ( "strings" vc "github.com/containers/virtcontainers" + "github.com/containers/virtcontainers/pkg/oci" specs "github.com/opencontainers/runtime-spec/specs-go" "github.com/sirupsen/logrus" "github.com/urfave/cli" @@ -194,6 +195,9 @@ func beforeSubcommands(context *cli.Context) error { // Set virtcontainers logger. vci.SetLogger(ccLog) + // Set the OCI package logger. + oci.SetLogger(ccLog) + ignoreLogging := false if context.NArg() == 1 && context.Args()[0] == "cc-env" { // "cc-env" should simply report the logging setup