]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
units: check if kmod command exists
authorYu Watanabe <watanabe.yu+github@gmail.com>
Fri, 11 Jul 2025 15:50:02 +0000 (00:50 +0900)
committerLuca Boccassi <luca.boccassi@gmail.com>
Mon, 4 Aug 2025 14:24:57 +0000 (15:24 +0100)
We already check existences of quotaon in quotaon@.service and
quotacheck in systemd-quotacheck@.service.
Let's also check if kmod command exists.

Closes #38179.

(cherry picked from commit 7c208a64bab5532235a05755d72aab78675b9ec3)

units/kmod-static-nodes.service.in

index 70605d997e0ab770bb9cddd9c0f9108882920e79..ec8c5da910ce19ff28c692d30a313338e8eb9f2c 100644 (file)
@@ -13,6 +13,7 @@ DefaultDependencies=no
 Before=sysinit.target systemd-tmpfiles-setup-dev-early.service
 ConditionCapability=CAP_SYS_MODULE
 ConditionFileNotEmpty=/lib/modules/%v/modules.devname
+ConditionPathExists={{KMOD}}
 
 [Service]
 Type=oneshot