feat(hyprland): ensure correct service order

This commit is contained in:
Moritz Böhme 2023-10-25 17:19:26 +02:00
parent da18eac2da
commit 300d5058c5
No known key found for this signature in database
GPG key ID: 970C6E89EB0547A9
4 changed files with 60 additions and 30 deletions

View file

@ -30,6 +30,10 @@ in
type = types.package;
default = pkgs.spotify-player;
};
target = mkOption {
type = types.str;
default = "graphical-session.target";
};
};
config = mkIf cfg.enable {
@ -44,9 +48,8 @@ in
}
];
systemd.user.services.spotify-player = {
after = [ "graphical-session.target" "network.target" ];
partOf = [ "graphical-session.target" ];
wantedBy = [ "graphical-session.target" ];
after = [ cfg.target "network.target" ];
wantedBy = [ cfg.target ];
serviceConfig = {
Type = "forking";
Restart = "always";