lol

nixos/systemd-oomd: add `After=swap.target` to fix swap detection issues

This should be removed after systemd 258 releases, as it is a temporary drop-in fix to circumvent the issue of systemd-oomd failing to detect a valid swap (noticeable in cases of users using `zram` as swap).

I've taken the liberty to clarify which `After=` override should be dropped when, based on the systemd version on Nixpkgs.

Ali Rizvi c372a3fb cbae5517

+5 -2
+5 -2
nixos/modules/system/boot/systemd/oomd.nix
··· 45 45 "systemd-oomd.service" 46 46 "systemd-oomd.socket" 47 47 ]; 48 - # TODO: Added upstream in upcoming systemd release. Good to drop once we use v258 or later 49 - systemd.services.systemd-oomd.after = [ "systemd-sysusers.service" ]; 48 + 49 + systemd.services.systemd-oomd.after = [ 50 + "swap.target" # TODO: drop after systemd v258 51 + "systemd-sysusers.service" # TODO: drop after systemd v257.8 52 + ]; 50 53 systemd.services.systemd-oomd.wantedBy = [ "multi-user.target" ]; 51 54 52 55 environment.etc."systemd/oomd.conf".text = lib.generators.toINI { } {