#!/bin/bash checkgroups() { getent group lock >/dev/null || groupadd -g 54 lock } post_install() { checkgroups [ -f /etc/machine-id ] || /bin/systemd-machine-id-setup echo "systemd has been installed to /bin/systemd. Please ensure you append" echo "init=/bin/systemd to your kernel command line in your bootloader." echo "Please disable and blacklist syslog-ng. Use rsyslog, which work correct with systemd." } post_upgrade() { checkgroups [ -f /etc/machine-id ] || /bin/systemd-machine-id-setup /bin/systemctl daemon-reexec >/dev/null || : } pre_remove() { /bin/rm -f /etc/systemd/system/default.target } post_remove() { getent group lock >/dev/null && groupdel lock }