From cbbc231210df5604719db57887b080637fd0e030 Mon Sep 17 00:00:00 2001 From: Feng Lee Date: Thu, 19 Jul 2018 10:08:37 +0800 Subject: [PATCH] Comment log.syslog.* to fix building issue --- etc/emqx.conf | 2 +- priv/emqx.schema | 25 +++++++++++++------------ 2 files changed, 14 insertions(+), 13 deletions(-) diff --git a/etc/emqx.conf b/etc/emqx.conf index b95e8b1f1..d13348908 100644 --- a/etc/emqx.conf +++ b/etc/emqx.conf @@ -391,7 +391,7 @@ log.crash.file = {{ platform_log_dir }}/crash.log ## Enable syslog. ## ## Values: on | off -## log.syslog = on +log.syslog = on ## Sets the severity level for syslog. ## diff --git a/priv/emqx.schema b/priv/emqx.schema index fe43f8f53..a3d2cfa32 100644 --- a/priv/emqx.schema +++ b/priv/emqx.schema @@ -442,7 +442,7 @@ end}. ]}. {mapping, "log.syslog", "lager.handlers", [ - {default, off}, + %%{default, off}, {datatype, flag} ]}. @@ -456,10 +456,10 @@ end}. {datatype, {enum, [daemon, local0, local1, local2, local3, local4, local5, local6, local7]}} ]}. -{mapping, "log.syslog.level", "lager.handlers", [ - {default, error}, - {datatype, {enum, [debug, info, notice, warning, error, critical, alert, emergency]}} -]}. +%%{mapping, "log.syslog.level", "lager.handlers", [ +%% {default, error}, +%% {datatype, {enum, [debug, info, notice, warning, error, critical, alert, emergency]}} +%%]}. {mapping, "log.error.redirect", "lager.error_logger_redirect", [ {default, on}, @@ -511,13 +511,14 @@ end}. both -> [ConsoleHandler, ConsoleFileHandler]; _ -> [] end, - SyslogHandler = case cuttlefish:conf_get("log.syslog", Conf) of - false -> []; - true -> [{lager_syslog_backend, - [cuttlefish:conf_get("log.syslog.identity", Conf), - cuttlefish:conf_get("log.syslog.facility", Conf), - cuttlefish:conf_get("log.syslog.level", Conf)]}] - end, + SyslogHandler = [], + %%case cuttlefish:conf_get("log.syslog", Conf, false) of + %% false -> []; + %% true -> [{lager_syslog_backend, + %% [cuttlefish:conf_get("log.syslog.identity", Conf), + %% cuttlefish:conf_get("log.syslog.facility", Conf), + %% cuttlefish:conf_get("log.syslog.level", Conf)]}] + %%end, ConsoleHandlers ++ ErrorHandler ++ InfoHandler ++ SyslogHandler end }.