diff options
author | Thomas Deutschmann <whissi@gentoo.org> | 2018-07-14 15:51:52 +0200 |
---|---|---|
committer | Thomas Deutschmann <whissi@gentoo.org> | 2018-07-14 15:52:13 +0200 |
commit | 4e136ce392501839c48f8ccfd7738f3afe6d8fec (patch) | |
tree | 9281ab9acc2939d6509eb4faa9a007b7654eb9cf /app-admin | |
parent | media-sound/qtscrobbler: Fix build with Qt 5.11 (diff) | |
download | gentoo-4e136ce392501839c48f8ccfd7738f3afe6d8fec.tar.gz gentoo-4e136ce392501839c48f8ccfd7738f3afe6d8fec.tar.bz2 gentoo-4e136ce392501839c48f8ccfd7738f3afe6d8fec.zip |
app-admin/rsyslog: fix logrotate for systemd users
Closes: https://bugs.gentoo.org/658842
Package-Manager: Portage-2.3.42, Repoman-2.3.9
RepoMan-Options: --force
Diffstat (limited to 'app-admin')
-rw-r--r-- | app-admin/rsyslog/files/8-stable/rsyslog-r1.logrotate | 45 | ||||
-rw-r--r-- | app-admin/rsyslog/rsyslog-8.35.0-r1.ebuild (renamed from app-admin/rsyslog/rsyslog-8.35.0.ebuild) | 2 | ||||
-rw-r--r-- | app-admin/rsyslog/rsyslog-8.36.0-r1.ebuild (renamed from app-admin/rsyslog/rsyslog-8.36.0.ebuild) | 2 |
3 files changed, 47 insertions, 2 deletions
diff --git a/app-admin/rsyslog/files/8-stable/rsyslog-r1.logrotate b/app-admin/rsyslog/files/8-stable/rsyslog-r1.logrotate new file mode 100644 index 000000000000..3a92ba37bdec --- /dev/null +++ b/app-admin/rsyslog/files/8-stable/rsyslog-r1.logrotate @@ -0,0 +1,45 @@ +# Uncomment the following directive if you have re-enabled +# "/var/log/syslog" in "/etc/rsyslog.d/50-default.conf" +#/var/log/syslog +#{ +# rotate 7 +# daily +# missingok +# notifempty +# delaycompress +# compress +# postrotate +# if type -p systemctl 2>&1 1>/dev/null && systemctl is-system-running 2>&1 1>/dev/null ; then +# systemctl kill -s HUP rsyslog.service +# else +# test -r /run/rsyslogd.pid && kill -HUP $(cat /run/rsyslogd.pid) 2>&1 1>/dev/null +# fi +# endscript +#} + +/var/log/auth.log +/var/log/cron.log +/var/log/daemon.log +/var/log/kern.log +/var/log/lpr.log +/var/log/mail.log +/var/log/news.log +/var/log/user.log +/var/log/debug.log +/var/log/messages +{ + rotate 4 + weekly + missingok + notifempty + compress + delaycompress + sharedscripts + postrotate + if type -p systemctl 2>&1 1>/dev/null && systemctl is-system-running 2>&1 1>/dev/null ; then + systemctl kill -s HUP rsyslog.service + else + test -r /run/rsyslogd.pid && kill -HUP $(cat /run/rsyslogd.pid) 2>&1 1>/dev/null + fi + endscript +} diff --git a/app-admin/rsyslog/rsyslog-8.35.0.ebuild b/app-admin/rsyslog/rsyslog-8.35.0-r1.ebuild index c11a69c68dee..88d35b15d840 100644 --- a/app-admin/rsyslog/rsyslog-8.35.0.ebuild +++ b/app-admin/rsyslog/rsyslog-8.35.0-r1.ebuild @@ -320,7 +320,7 @@ src_install() { newins "${FILESDIR}/${BRANCH}/50-default-r1.conf" 50-default.conf insinto /etc/logrotate.d/ - newins "${FILESDIR}/${BRANCH}/${PN}.logrotate" ${PN} + newins "${FILESDIR}/${BRANCH}/${PN}-r1.logrotate" ${PN} if use mysql; then insinto /usr/share/doc/${PF}/scripts/mysql diff --git a/app-admin/rsyslog/rsyslog-8.36.0.ebuild b/app-admin/rsyslog/rsyslog-8.36.0-r1.ebuild index 023b88252ce1..cf864d50b49b 100644 --- a/app-admin/rsyslog/rsyslog-8.36.0.ebuild +++ b/app-admin/rsyslog/rsyslog-8.36.0-r1.ebuild @@ -329,7 +329,7 @@ src_install() { newins "${FILESDIR}/${BRANCH}/50-default-r1.conf" 50-default.conf insinto /etc/logrotate.d/ - newins "${FILESDIR}/${BRANCH}/${PN}.logrotate" ${PN} + newins "${FILESDIR}/${BRANCH}/${PN}-r1.logrotate" ${PN} if use mysql; then insinto /usr/share/doc/${PF}/scripts/mysql |