Using udev rules you can create systemd targets for batterystate or AC-state. This is really useful, as services can then depend on these targets. Example; only autoupdate dnf when battery is full or AC is attached. This is even more important for "grandma devices" where you want automatic firmware updates. Having the base targets "ac" and "battery", "battery full" and "battery empty" would make it easy for these services to be implemented or easily deployed, as they work on every system. If it is possible to detect network states easily, this would be great too. On Android you csn safe cell data a lot, as good apps dont load images, there are no updates and all. At least automatic updates should be easy to pause on cell networks, and using a config file also other networks for example a phone hotspot. Reproducible: Always Actual Results: There are no ways to control services only running at a certain battery state or network Expected Results: More control and easy possibility to depend on these markers for dependencies in systemd services Some udev rules, maybe combined services "critical state" (low battery AND no charger) or "save state" (high battery OR low battery AND charger) Some way to detect metered connections and also state other connections manually
For RFE's, please open an upstream ticket (https://github.com/systemd/systemd/issues) or even better write to systemd-devel.org to discuss those ideas. The Fedora tracker is not the best place for such things, because most upstream developers will not see the discussion here.