mirror of
https://gitdl.cn/https://github.com/chakralinux/core.git
synced 2025-01-24 02:22:15 +08:00
24 lines
528 B
Plaintext
24 lines
528 B
Plaintext
post_install() {
|
|
getent group dbus >/dev/null || groupadd -g 81 dbus
|
|
getent passwd dbus >/dev/null || useradd -c 'System message bus' -u 81 -g dbus -d '/' -s /bin/false dbus
|
|
passwd -l dbus &>/dev/null
|
|
}
|
|
|
|
post_upgrade() {
|
|
post_install
|
|
|
|
# Make sure new rc script can shutdown running dbus
|
|
if [ -f run/dbus.pid -a -d run/dbus ]; then
|
|
mv run/dbus.pid run/dbus/pid
|
|
fi
|
|
}
|
|
|
|
post_remove() {
|
|
if getent passwd dbus >/dev/null; then
|
|
userdel dbus
|
|
fi
|
|
if getent group dbus >/dev/null; then
|
|
groupdel dbus
|
|
fi
|
|
}
|