services: change dependency requirement

I didn't realize `network.target` is very ambiguous. The next best thing
for booting up the service after the system is up is `default.target`
but we're being explicit here for NixOS services just to make sure.
This commit is contained in:
Gabriel Arazas 2022-07-22 15:00:15 +08:00
parent ddba7b0bea
commit 906ea48993
4 changed files with 4 additions and 4 deletions

View File

@ -165,7 +165,7 @@ in {
lib.nameValuePair "gallery-dl-archive-service-${name}" { lib.nameValuePair "gallery-dl-archive-service-${name}" {
Unit = { Unit = {
Description = "gallery-dl archive job for group '${name}'"; Description = "gallery-dl archive job for group '${name}'";
After = "network.target"; After = "default.target";
Documentation = "man:gallery-dl(1)"; Documentation = "man:gallery-dl(1)";
}; };

View File

@ -135,7 +135,7 @@ in {
lib.nameValuePair "yt-dlp-archive-service-${name}" { lib.nameValuePair "yt-dlp-archive-service-${name}" {
Unit = { Unit = {
Description = "yt-dlp archive job for group '${name}'"; Description = "yt-dlp archive job for group '${name}'";
After = "network.target"; After = "default.target";
Documentation = "man:yt-dlp(1)"; Documentation = "man:yt-dlp(1)";
}; };

View File

@ -157,7 +157,7 @@ in {
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
systemd.services = lib.mapAttrs' (name: value: systemd.services = lib.mapAttrs' (name: value:
lib.nameValuePair "gallery-dl-archive-service-${name}" { lib.nameValuePair "gallery-dl-archive-service-${name}" {
after = [ "network.target" ]; wantedBy = [ "multi-user.target" ];
description = "gallery-dl archive job for group '${name}'"; description = "gallery-dl archive job for group '${name}'";
documentation = [ "man:gallery-dl(1)" ]; documentation = [ "man:gallery-dl(1)" ];
enable = true; enable = true;

View File

@ -128,7 +128,7 @@ in {
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
systemd.services = lib.mapAttrs' (name: value: systemd.services = lib.mapAttrs' (name: value:
lib.nameValuePair "yt-dlp-archive-service-${name}" { lib.nameValuePair "yt-dlp-archive-service-${name}" {
after = [ "network.target" ]; wantedBy = [ "multi-user.target" ];
description = "yt-dlp archive job for group '${name}'"; description = "yt-dlp archive job for group '${name}'";
documentation = [ "man:yt-dlp(1)" ]; documentation = [ "man:yt-dlp(1)" ];
enable = true; enable = true;