diff options
author | Remi Collet <fedora@famillecollet.com> | 2016-04-05 08:42:57 +0200 |
---|---|---|
committer | Remi Collet <fedora@famillecollet.com> | 2016-04-05 08:42:57 +0200 |
commit | d797654c7720efc552b1151862ecdaa1171065be (patch) | |
tree | d9d891e95dad897b32f87edc6e34d6c2fd749e1d | |
parent | 5b64ff8f30058852f613b7a4eb795edabc350baa (diff) |
glpi: fix logrotate
-rw-r--r-- | glpi-logrotate | 1 | ||||
-rw-r--r-- | glpi.spec | 9 |
2 files changed, 9 insertions, 1 deletions
diff --git a/glpi-logrotate b/glpi-logrotate index e25627f..e92b6cf 100644 --- a/glpi-logrotate +++ b/glpi-logrotate @@ -1,6 +1,7 @@ # Rotate GLPI logs daily, only if not empty # Save 14 days old logs under compressed mode /var/log/glpi/*.log { + su apache apache daily rotate 14 compress @@ -28,7 +28,7 @@ Name: glpi Version: 0.90.2 -Release: 1%{?dist} +Release: 2%{?dist} Summary: Free IT asset management software Summary(fr): Gestion Libre de Parc Informatique @@ -220,6 +220,10 @@ mkdir -p %{buildroot}%{_localstatedir}/log mv %{buildroot}/%{_localstatedir}/lib/%{name}/files/_log %{buildroot}%{_localstatedir}/log/%{name} install -Dpm 0644 %{SOURCE3} %{buildroot}%{_sysconfdir}/logrotate.d/%{name} +%if 0%{?rhel} == 5 || 0%{?rhel} == 6 +: Remove "su" option from logrotate configuration file - requires logrotate 3.8+ +sed -e '/su /d' -i %{buildroot}%{_sysconfdir}/logrotate.d/%{name} +%endif # ====== Cron ===== install -Dpm 0644 cron %{buildroot}%{_sysconfdir}/cron.d/%{name} @@ -323,6 +327,9 @@ fi %changelog +* Tue Apr 5 2016 Remi Collet <remi@fedoraproject.org> - 0.90.2-2 +- fix logrotate configuration for recent version + * Fri Apr 1 2016 Remi Collet <remi@fedoraproject.org> - 0.90.2-1 - update to 0.90.2 |