diff options
author | Bertrand Jacquin <bertrand@jacquin.bzh> | 2016-09-18 22:23:58 +0100 |
---|---|---|
committer | Bertrand Jacquin <bertrand@jacquin.bzh> | 2016-09-18 23:53:33 +0100 |
commit | 883db27c0ab37691830fd027bda6935c107ff29c (patch) | |
tree | 471e9584d993f21287cf5ca7da65c4473aa71ad5 | |
parent | factory-default/app-admin/syslog-ng: Move template, perm, owner, group to glo... (diff) | |
download | portage-883db27c0ab37691830fd027bda6935c107ff29c.tar.xz |
factory-default/app-admin/syslog-ng: Split d_net config
-rw-r--r-- | factory-default/app-admin/syslog-ng/etc/syslog-ng/conf.d/0001-send-via-syslog.conf | 14 | ||||
-rw-r--r-- | factory-default/app-admin/syslog-ng/etc/syslog-ng/syslog-ng.conf | 18 |
2 files changed, 19 insertions, 13 deletions
diff --git a/factory-default/app-admin/syslog-ng/etc/syslog-ng/conf.d/0001-send-via-syslog.conf b/factory-default/app-admin/syslog-ng/etc/syslog-ng/conf.d/0001-send-via-syslog.conf new file mode 100644 index 00000000..81d79a61 --- /dev/null +++ b/factory-default/app-admin/syslog-ng/etc/syslog-ng/conf.d/0001-send-via-syslog.conf @@ -0,0 +1,14 @@ +destination d_net { + syslog("log.as29.net" + transport(tls) + tls(ca_dir("/etc/ssl/certs") + peer_verify(required-trusted) + cipher-suite(AES256-GCM-SHA384) + ) + ); +}; + +log { + source(s_local); + destination(d_net); +}; diff --git a/factory-default/app-admin/syslog-ng/etc/syslog-ng/syslog-ng.conf b/factory-default/app-admin/syslog-ng/etc/syslog-ng/syslog-ng.conf index 2602da23..d941a475 100644 --- a/factory-default/app-admin/syslog-ng/etc/syslog-ng/syslog-ng.conf +++ b/factory-default/app-admin/syslog-ng/etc/syslog-ng/syslog-ng.conf @@ -53,7 +53,9 @@ source s_local { udp(ip(127.0.0.1)); }; -template t_logformat { template("${ISODATE} ${FACILITY}.${PRIORITY} ${HOST} ${MSGHDR}${MSGONLY}\n"); }; +template t_logformat { + template("${ISODATE} ${FACILITY}.${PRIORITY} ${HOST} ${MSGHDR}${MSGONLY}\n"); +}; filter f_auth { facility(auth, authpriv); }; filter f_cron { facility(cron); }; @@ -70,6 +72,8 @@ filter f_apache_access { program("httpd") and facility(local2); } filter f_apache_error { program("httpd") and facility(local3); }; filter f_php_error { program("apache2") and facility(user); }; +@include "/etc/syslog-ng/conf.d" + destination d_auth { file("/var/log/auth.log" ); }; destination d_cron { file("/var/log/cron.log" ); }; destination d_daemon { file("/var/log/daemon.log" ); }; @@ -84,18 +88,6 @@ destination d_apache_access { file("/var/log/apache2/access.log"); }; destination d_apache_error { file("/var/log/apache2/error.log" ); }; destination d_haproxy { file("/var/log/haproxy.log" ); }; -destination d_net { - syslog("log.as29.net" - transport(tls) - tls(ca_dir("/etc/ssl/certs") - peer_verify(required-trusted) - cipher-suite(AES256-GCM-SHA384) - ) - ); -}; - -log { source(s_local); destination(d_net); }; - log { source(s_local); filter(f_firewall); destination(d_firewall); flags(final); }; log { source(s_local); filter(f_haproxy); destination(d_haproxy); flags(final); }; log { source(s_local); filter(f_apache_access); destination(d_apache_access); flags(final); }; |