summaryrefslogtreecommitdiffstats
path: root/remote/modules/systemd/data/etc
diff options
context:
space:
mode:
authorChristian Rößler2013-10-07 15:49:22 +0200
committerChristian Rößler2013-10-07 15:49:22 +0200
commit45914431f11ceecbf0963af0005493bd6c8a109d (patch)
tree73d08d0e7c04492ba1f2e4c8b9e61d86619f93ad /remote/modules/systemd/data/etc
parentMerge branch 'master' of git.openslx.org:openslx-ng/tm-scripts (diff)
downloadtm-scripts-45914431f11ceecbf0963af0005493bd6c8a109d.tar.gz
tm-scripts-45914431f11ceecbf0963af0005493bd6c8a109d.tar.xz
tm-scripts-45914431f11ceecbf0963af0005493bd6c8a109d.zip
[systemd] Amended shutdown behaviour for systemd: reboot, halt, poweroff. nfs
and samba (cifs) umount script hooked via ExecStartPre; script will include kill routines etc. later on for faster shutdowns. Patched services r/h/s.
Diffstat (limited to 'remote/modules/systemd/data/etc')
-rw-r--r--remote/modules/systemd/data/etc/systemd/system/systemd-halt.service18
-rw-r--r--remote/modules/systemd/data/etc/systemd/system/systemd-poweroff.service18
-rw-r--r--remote/modules/systemd/data/etc/systemd/system/systemd-reboot.service18
3 files changed, 54 insertions, 0 deletions
diff --git a/remote/modules/systemd/data/etc/systemd/system/systemd-halt.service b/remote/modules/systemd/data/etc/systemd/system/systemd-halt.service
new file mode 100644
index 00000000..95b4f284
--- /dev/null
+++ b/remote/modules/systemd/data/etc/systemd/system/systemd-halt.service
@@ -0,0 +1,18 @@
+# This file is part of systemd.
+#
+# systemd is free software; you can redistribute it and/or modify it
+# under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or
+# (at your option) any later version.
+
+[Unit]
+Description=Halt
+Documentation=man:systemd-halt.service(8)
+DefaultDependencies=no
+Requires=shutdown.target final.target
+After=shutdown.target final.target
+
+[Service]
+Type=oneshot
+ExecStartPre=-/bin/bash -c /opt/openslx/scripts/systemd-shutdown_prescript
+ExecStart=/usr/bin/systemctl --force halt
diff --git a/remote/modules/systemd/data/etc/systemd/system/systemd-poweroff.service b/remote/modules/systemd/data/etc/systemd/system/systemd-poweroff.service
new file mode 100644
index 00000000..8b96980e
--- /dev/null
+++ b/remote/modules/systemd/data/etc/systemd/system/systemd-poweroff.service
@@ -0,0 +1,18 @@
+# This file is part of systemd.
+#
+# systemd is free software; you can redistribute it and/or modify it
+# under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or
+# (at your option) any later version.
+
+[Unit]
+Description=Power-Off
+Documentation=man:systemd-halt.service(8)
+DefaultDependencies=no
+Requires=shutdown.target final.target
+After=shutdown.target final.target
+
+[Service]
+Type=oneshot
+ExecStartPre=-/bin/bash -c /opt/openslx/scripts/systemd-shutdown_prescript
+ExecStart=/usr/bin/systemctl --force poweroff
diff --git a/remote/modules/systemd/data/etc/systemd/system/systemd-reboot.service b/remote/modules/systemd/data/etc/systemd/system/systemd-reboot.service
new file mode 100644
index 00000000..be4d608c
--- /dev/null
+++ b/remote/modules/systemd/data/etc/systemd/system/systemd-reboot.service
@@ -0,0 +1,18 @@
+# This file is part of systemd.
+#
+# systemd is free software; you can redistribute it and/or modify it
+# under the terms of the GNU Lesser General Public License as published by
+# the Free Software Foundation; either version 2.1 of the License, or
+# (at your option) any later version.
+
+[Unit]
+Description=Reboot
+Documentation=man:systemd-halt.service(8)
+DefaultDependencies=no
+Requires=shutdown.target final.target
+After=shutdown.target final.target
+
+[Service]
+Type=oneshot
+ExecStartPre=-/bin/bash -c /opt/openslx/scripts/systemd-shutdown_prescript
+ExecStart=/usr/bin/systemctl --force reboot