[lxc-devel] [lxd/master] lxd: Fix logging events

stgraber on Github lxc-bot at linuxcontainers.org
Fri Mar 23 01:13:36 UTC 2018


A non-text attachment was scrubbed...
Name: not available
Type: text/x-mailbox
Size: 354 bytes
Desc: not available
URL: <http://lists.linuxcontainers.org/pipermail/lxc-devel/attachments/20180323/38c36695/attachment.bin>
-------------- next part --------------
From e2999fdf274c6d4fcaa0ed1591526c1db3eb69b4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?St=C3=A9phane=20Graber?= <stgraber at ubuntu.com>
Date: Thu, 22 Mar 2018 21:12:42 -0400
Subject: [PATCH] lxd: Fix logging events
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Signed-off-by: Stéphane Graber <stgraber at ubuntu.com>
---
 lxd/main.go | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lxd/main.go b/lxd/main.go
index 7a3be32d5..64db8d036 100644
--- a/lxd/main.go
+++ b/lxd/main.go
@@ -43,7 +43,8 @@ func (c *cmdGlobal) Run(cmd *cobra.Command, args []string) error {
 		syslog = "lxd"
 	}
 
-	log, err := logging.GetLogger(syslog, c.flagLogFile, c.flagLogVerbose, c.flagLogDebug, nil)
+	handler := eventsHandler{}
+	log, err := logging.GetLogger(syslog, c.flagLogFile, c.flagLogVerbose, c.flagLogDebug, handler)
 	if err != nil {
 		return err
 	}


More information about the lxc-devel mailing list