summaryrefslogtreecommitdiff
path: root/community-testing/systemd/systemd.install
diff options
context:
space:
mode:
authorroot <root@rshg047.dnsready.net>2011-07-15 23:12:20 +0000
committerroot <root@rshg047.dnsready.net>2011-07-15 23:12:20 +0000
commit76c26b027d797f3671bf0b6c6618eda2496cf88d (patch)
treec386be56a0a3bc7b668a674e9cec6405a4d2fb2f /community-testing/systemd/systemd.install
parent29657877f6a02dbba1bd58b417b4ccd211939690 (diff)
Fri Jul 15 23:12:20 UTC 2011
Diffstat (limited to 'community-testing/systemd/systemd.install')
-rw-r--r--community-testing/systemd/systemd.install31
1 files changed, 31 insertions, 0 deletions
diff --git a/community-testing/systemd/systemd.install b/community-testing/systemd/systemd.install
new file mode 100644
index 000000000..b4228255d
--- /dev/null
+++ b/community-testing/systemd/systemd.install
@@ -0,0 +1,31 @@
+#!/bin/sh
+
+checkgroups() {
+ getent group lock >/dev/null || groupadd -g 54 lock
+}
+
+post_install() {
+ checkgroups
+
+ [ -f etc/machine-id ] || 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."
+}
+
+post_upgrade() {
+ checkgroups
+
+ [ -f etc/machine-id ] || systemd-machine-id-setup
+ systemctl daemon-reexec >/dev/null || :
+}
+
+pre_remove() {
+ rm -f /etc/systemd/system/default.target
+}
+
+post_remove() {
+ getent group lock >/dev/null && groupdel lock
+}
+
+# vim:set ts=2 sw=2 et: