[systemd] Remove duplicate ACLs in %post

Zbigniew Jędrzejewski-Szmek zbyszek at fedoraproject.org
Wed Mar 4 01:08:12 UTC 2015


commit b081c530a56f2160ab9b5ac45348037eacceaa95
Author: Zbigniew Jędrzejewski-Szmek <zbyszek at in.waw.pl>
Date:   Tue Mar 3 13:59:56 2015 -0500

    Remove duplicate ACLs in %post
    
    This fixes a problem added during development, so it should be enough
    to carry the scriplet for some time and remove it in all branches before
    F22 goes stable.

 systemd.spec | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
---
diff --git a/systemd.spec b/systemd.spec
index c4d4586..829e678 100644
--- a/systemd.spec
+++ b/systemd.spec
@@ -496,6 +496,10 @@ chmod g+s /run/log/journal/ /run/log/journal/`cat /etc/machine-id 2> /dev/null`
 # Apply ACL to the journal directory
 setfacl -Rnm g:wheel:rx,d:g:wheel:rx,g:adm:rx,d:g:adm:rx /var/log/journal/ >/dev/null 2>&1 || :
 
+# Remove duplicate ACL entries on /var/log/journal/<id>
+# This should be removed before before F22 or F23 release
+getfacl -p /var/log/journal/`cat /etc/machine-id`|grep -v '^#'|sort -u|setfacl --set-file=- /var/log/journal/`cat /etc/machine-id` >/dev/null 2>&1 || :
+
 # Move old stuff around in /var/lib
 mv %{_localstatedir}/lib/random-seed %{_localstatedir}/lib/systemd/random-seed >/dev/null 2>&1 || :
 mv %{_localstatedir}/lib/backlight %{_localstatedir}/lib/systemd/backlight >/dev/null 2>&1 || :
@@ -885,7 +889,7 @@ getent passwd systemd-journal-upload >/dev/null 2>&1 || useradd -r -l -g systemd
 %changelog
 * Tue Mar  3 2015 Zbigniew Jędrzejewski-Szmek <zbyszek at in.waw.pl> - 219-8
 - Reworked device handling (#1195761)
-- ACL handling fixes
+- ACL handling fixes (with a script in %%post)
 - Various log messages downgraded (#1184712)
 
 * Wed Feb 25 2015 Michal Schmidt <mschmidt at redhat.com> - 219-7


More information about the scm-commits mailing list