diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2020-03-05 07:20:49 +0100 |
---|---|---|
committer | Chris Down <chris@chrisdown.name> | 2020-03-05 19:43:50 +0100 |
commit | 9cbf1e58f9629af5c6b56777ee73dc6320306d6d (patch) | |
tree | 30e26ff5099f29d11f6ec7668c179ab45bedc206 /units/modprobe@.service | |
parent | treewide: more portable bash shebangs (diff) | |
download | systemd-9cbf1e58f9629af5c6b56777ee73dc6320306d6d.tar.xz systemd-9cbf1e58f9629af5c6b56777ee73dc6320306d6d.zip |
units: skip modprobe@.service if the unit appears to be already loaded
Possible alternative to #14819.
For me, setting RemainAfterExit=yes would be OK, but if people think that it
might cause issues, then this could be a reasonable alternative that still
let's us skip the invocation of the separate binary.
Diffstat (limited to 'units/modprobe@.service')
-rw-r--r-- | units/modprobe@.service | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/units/modprobe@.service b/units/modprobe@.service index 5dca2cb771..34a0557735 100644 --- a/units/modprobe@.service +++ b/units/modprobe@.service @@ -13,6 +13,7 @@ DefaultDependencies=no Before=sysinit.target Documentation=man:modprobe(8) ConditionCapability=CAP_SYS_MODULE +ConditionPathExists=!/sys/module/%I [Service] Type=oneshot |