mirror of
https://github.com/ryan4yin/nix-config.git
synced 2026-11-13 12:13:36 +01:00
fix(power): mask the package's tuned-ppd unit when ppdSupport is off (#460)
The tuned package ships tuned-ppd.service with WantedBy=graphical.target, so activation starts it without /etc/tuned/ppd.conf and switch-to-configuration exits 4. Assisted-by: DeepSeek Harness (deepseek-flash)
This commit is contained in:
1 parent
b4b293ebfa
commit
643984e1ab
1 file changed
+7
-1
@@ -1,4 +1,4 @@
|
||||
{ ... }:
|
||||
{ config, lib, ... }:
|
||||
{
|
||||
# TuneD - Tuning Profile Delivery Mechanism for Linux
|
||||
# A modern replacement for PPD(power-profiles-daemon), and the only power manager
|
||||
@@ -20,4 +20,10 @@
|
||||
|
||||
# Battery/AC state, used by the desktops; tuned-ppd was the other consumer.
|
||||
services.upower.enable = true;
|
||||
|
||||
# ppdSupport = false drops /etc/tuned/ppd.conf, but the tuned package ships its
|
||||
# own tuned-ppd.service (WantedBy=graphical.target) which systemd.packages links
|
||||
# regardless, so activation starts it, it fails on the missing config file and
|
||||
# switch-to-configuration exits 4. Mask it.
|
||||
systemd.units."tuned-ppd.service".enable = lib.mkIf (!config.services.tuned.ppdSupport) false;
|
||||
}
|
||||
Reference in new issue
Block a user