[packages/syslog-ng] - cron daemons log through syslog - syslog packages own cron log file and rotate it

bszx bszx at pld-linux.org
Thu Oct 15 15:16:24 CEST 2015


commit 6d64ef6a3709b876f9d60bc6ac30695de645b167
Author: Bartek Szady <bszx at bszx.eu>
Date:   Tue Oct 6 12:49:17 2015 +0200

    - cron daemons log through syslog
    - syslog packages own cron log file and rotate it

 syslog-ng.conf      |  2 +-
 syslog-ng.logrotate |  1 +
 syslog-ng.spec      | 29 +++++++++++++++--------------
 3 files changed, 17 insertions(+), 15 deletions(-)
---
diff --git a/syslog-ng.spec b/syslog-ng.spec
index faa11ac..43477cc 100644
--- a/syslog-ng.spec
+++ b/syslog-ng.spec
@@ -33,7 +33,7 @@ Summary(pl.UTF-8):	Syslog-ng - systemowy demon logujący nowej generacji
 Summary(pt_BR.UTF-8):	Daemon de log nova geração
 Name:		syslog-ng
 Version:	3.6.4
-Release:	1
+Release:	2
 License:	GPL v2+ with OpenSSL exception
 Group:		Daemons
 Source0:	https://my.balabit.com/downloads/syslog-ng/open-source-edition/%{version}/source/%{name}_%{version}.tar.gz
@@ -392,7 +392,7 @@ ln -snf %{slibdir}/$(basename $RPM_BUILD_ROOT%{slibdir}/libsyslog-ng-%{mver}.so.
 cp -p %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/syslog-ng/syslog-ng.conf
 cp -p %{SOURCE3} $RPM_BUILD_ROOT/etc/logrotate.d/syslog-ng
 
-for n in daemon debug iptables kernel lpr maillog messages secure spooler syslog user xferlog; do
+for n in cron daemon debug iptables kernel lpr maillog messages secure spooler syslog user xferlog; do
 	> $RPM_BUILD_ROOT/var/log/$n
 done
 touch $RPM_BUILD_ROOT/etc/sysconfig/%{name}
@@ -526,18 +526,19 @@ exit 0
 %{_mandir}/man5/syslog-ng.conf.5*
 %{_mandir}/man8/syslog-ng.8*
 
-%attr(640,root,root) %ghost /var/log/daemon
-%attr(640,root,root) %ghost /var/log/debug
-%attr(640,root,root) %ghost /var/log/iptables
-%attr(640,root,root) %ghost /var/log/kernel
-%attr(640,root,root) %ghost /var/log/lpr
-%attr(640,root,root) %ghost /var/log/maillog
-%attr(640,root,root) %ghost /var/log/messages
-%attr(640,root,root) %ghost /var/log/secure
-%attr(640,root,root) %ghost /var/log/spooler
-%attr(640,root,root) %ghost /var/log/syslog
-%attr(640,root,root) %ghost /var/log/user
-%attr(640,root,root) %ghost /var/log/xferlog
+%attr(640,root,logs) %ghost /var/log/cron
+%attr(640,root,logs) %ghost /var/log/daemon
+%attr(640,root,logs) %ghost /var/log/debug
+%attr(640,root,logs) %ghost /var/log/iptables
+%attr(640,root,logs) %ghost /var/log/kernel
+%attr(640,root,logs) %ghost /var/log/lpr
+%attr(640,root,logs) %ghost /var/log/maillog
+%attr(640,root,logs) %ghost /var/log/messages
+%attr(640,root,logs) %ghost /var/log/secure
+%attr(640,root,logs) %ghost /var/log/spooler
+%attr(640,root,logs) %ghost /var/log/syslog
+%attr(640,root,logs) %ghost /var/log/user
+%attr(640,root,logs) %ghost /var/log/xferlog
 
 %if %{with mongodb}
 %files module-afmongodb
diff --git a/syslog-ng.conf b/syslog-ng.conf
index 5936c16..5125041 100644
--- a/syslog-ng.conf
+++ b/syslog-ng.conf
@@ -43,7 +43,7 @@ destination d_authlog	{ file("/var/log/secure"); };
 destination d_mail	{ file("/var/log/maillog"); };
 destination d_uucp	{ file("/var/log/spooler"); };
 destination d_debug	{ file("/var/log/debug"); };
-destination d_cron	{ file("/var/log/cron" owner(root) group(crontab) perm(0660)); };
+destination d_cron	{ file("/var/log/cron"); };
 destination d_syslog	{ file("/var/log/syslog"); };
 destination d_daemon	{ file("/var/log/daemon"); };
 destination d_lpr		{ file("/var/log/lpr"); };
diff --git a/syslog-ng.logrotate b/syslog-ng.logrotate
index 97b8e53..fcf6144 100644
--- a/syslog-ng.logrotate
+++ b/syslog-ng.logrotate
@@ -1,3 +1,4 @@
+/var/log/cron
 /var/log/daemon
 /var/log/debug
 /var/log/iptables
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/syslog-ng.git/commitdiff/6d64ef6a3709b876f9d60bc6ac30695de645b167



More information about the pld-cvs-commit mailing list