From f707f212378f9d8de103ac96abcd9d377a2605a8 Mon Sep 17 00:00:00 2001 From: clerie Date: Sun, 24 Mar 2024 14:42:46 +0100 Subject: [PATCH] Make sure required services are started in nix modules --- nix/modules/fieldpoc.nix | 1 + nix/modules/yate.nix | 1 + 2 files changed, 2 insertions(+) diff --git a/nix/modules/fieldpoc.nix b/nix/modules/fieldpoc.nix index 58cfbd4..b4376db 100644 --- a/nix/modules/fieldpoc.nix +++ b/nix/modules/fieldpoc.nix @@ -31,6 +31,7 @@ in { systemd.services.fieldpoc = { description = "Fieldpoc daemon"; wantedBy = [ "multi-user.target" ]; + requires = [ "network-online.target" "yate.service" ]; after = [ "network-online.target" "yate.service" ]; serviceConfig = { diff --git a/nix/modules/yate.nix b/nix/modules/yate.nix index 3084a6b..67d1dc7 100644 --- a/nix/modules/yate.nix +++ b/nix/modules/yate.nix @@ -21,6 +21,7 @@ in { systemd.services.yate = { description = "YATE Telephony Server"; wantedBy = [ "multi-user.target" ]; + requires = [ "network-online.target" "postgresql.service" ]; after = [ "network-online.target" "postgresql.service" ]; environment = { PWLIB_ASSERT_ACTION = "C"; };