summaryrefslogtreecommitdiffstats
path: root/units/systemd-sysext.service
diff options
context:
space:
mode:
authorLuca Boccassi <luca.boccassi@microsoft.com>2021-01-19 18:23:57 +0100
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2021-01-20 15:25:03 +0100
commitaac5fbff0b03e85ea156cf0bd821bd90c1b89096 (patch)
treeb7a5cbba7f08c3424d832ee9298535a25aa8af35 /units/systemd-sysext.service
parentudev: use DEFINE_MAIN_FUNCTION in cdrom_id (diff)
downloadsystemd-aac5fbff0b03e85ea156cf0bd821bd90c1b89096.tar.xz
systemd-aac5fbff0b03e85ea156cf0bd821bd90c1b89096.zip
sysext: install in rootbindir, remove template from unit
This reverts commit 71ad75f30641b90f9ca0088869f164d9d085430f.
Diffstat (limited to 'units/systemd-sysext.service')
-rw-r--r--units/systemd-sysext.service31
1 files changed, 31 insertions, 0 deletions
diff --git a/units/systemd-sysext.service b/units/systemd-sysext.service
new file mode 100644
index 0000000000..cc31f9ca9b
--- /dev/null
+++ b/units/systemd-sysext.service
@@ -0,0 +1,31 @@
+# SPDX-License-Identifier: LGPL-2.1-or-later
+#
+# 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=Merge System Extension Images into /usr/ and /opt/
+Documentation=man:systemd-sysext.service(8)
+DefaultDependencies=no
+Conflicts=shutdown.target
+After=local-fs.target
+Before=sysinit.target shutdown.target systemd-tmpfiles.service
+ConditionCapability=CAP_SYS_ADMIN
+ConditionDirectoryNotEmpty=|/etc/extensions
+ConditionDirectoryNotEmpty=|/run/extensions
+ConditionDirectoryNotEmpty=|/var/lib/extensions
+ConditionDirectoryNotEmpty=|/usr/local/lib/extensions
+ConditionDirectoryNotEmpty=|/usr/lib/extensions
+
+[Service]
+Type=oneshot
+RemainAfterExit=yes
+ExecStart=systemd-sysext --merge
+ExecStop=systemd-sysext --unmerge
+
+[Install]
+WantedBy=sysinit.target