mirror of
https://github.com/flatcar/scripts.git
synced 2025-08-15 17:06:58 +02:00
sys-auth/polkit: Apply Flatcar modifications
- Fix config install paths, use systemd-tmpfiles (all configs should be installed to /usr and tmpfiles should be used to create and fix directory permissions instead of the ebuild's postinst.) Signed-off-by: Mathieu Tortuyaux <mtortuyaux@microsoft.com>
This commit is contained in:
parent
f57c8c8ecd
commit
1a2cc3e309
3
sdk_container/src/third_party/coreos-overlay/sys-auth/polkit/files/polkit.conf
vendored
Normal file
3
sdk_container/src/third_party/coreos-overlay/sys-auth/polkit/files/polkit.conf
vendored
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
d /etc/polkit-1 - - - - -
|
||||||
|
d /etc/polkit-1/rules.d 0700 polkitd root - -
|
||||||
|
d /var/lib/polkit-1 0700 polkitd polkitd - -
|
@ -4,7 +4,8 @@
|
|||||||
EAPI=8
|
EAPI=8
|
||||||
|
|
||||||
PYTHON_COMPAT=( python3_{8..11} )
|
PYTHON_COMPAT=( python3_{8..11} )
|
||||||
inherit meson pam pax-utils python-any-r1 systemd xdg-utils
|
TMPFILES_OPTIONAL=1
|
||||||
|
inherit meson pam pax-utils python-any-r1 systemd tmpfiles xdg-utils
|
||||||
|
|
||||||
DESCRIPTION="Policy framework for controlling privileges for system-wide services"
|
DESCRIPTION="Policy framework for controlling privileges for system-wide services"
|
||||||
HOMEPAGE="https://www.freedesktop.org/wiki/Software/polkit https://gitlab.freedesktop.org/polkit/polkit"
|
HOMEPAGE="https://www.freedesktop.org/wiki/Software/polkit https://gitlab.freedesktop.org/polkit/polkit"
|
||||||
@ -137,6 +138,16 @@ src_compile() {
|
|||||||
src_install() {
|
src_install() {
|
||||||
meson_src_install
|
meson_src_install
|
||||||
|
|
||||||
|
dodir /usr/share/polkit-1/rules.d
|
||||||
|
dodir /usr/lib/pam.d
|
||||||
|
|
||||||
|
mv "${D}"/{etc,usr/share}/polkit-1/rules.d/50-default.rules || die
|
||||||
|
mv "${D}"/{etc,usr/lib}/pam.d/polkit-1 || die
|
||||||
|
rmdir "${D}"/etc/polkit-1/rules.d "${D}"/etc/polkit-1 || die
|
||||||
|
rmdir "${D}"/etc/pam.d || die
|
||||||
|
|
||||||
|
dotmpfiles "${FILESDIR}/polkit.conf"
|
||||||
|
|
||||||
if use examples ; then
|
if use examples ; then
|
||||||
docinto examples
|
docinto examples
|
||||||
dodoc src/examples/{*.c,*.policy*}
|
dodoc src/examples/{*.c,*.policy*}
|
||||||
@ -145,8 +156,3 @@ src_install() {
|
|||||||
diropts -m 0700 -o polkitd
|
diropts -m 0700 -o polkitd
|
||||||
keepdir /usr/share/polkit-1/rules.d
|
keepdir /usr/share/polkit-1/rules.d
|
||||||
}
|
}
|
||||||
|
|
||||||
pkg_postinst() {
|
|
||||||
chmod 0700 "${EROOT}"/{etc,usr/share}/polkit-1/rules.d
|
|
||||||
chown polkitd "${EROOT}"/{etc,usr/share}/polkit-1/rules.d
|
|
||||||
}
|
|
||||||
|
Loading…
Reference in New Issue
Block a user