add wants to services using network-online.target

c2853e2588
This commit is contained in:
zowoq 2024-01-22 13:07:47 +10:00
parent ebe2b9186d
commit c03246f531
3 changed files with 5 additions and 0 deletions
modules/nixos/monitoring

View file

@ -1,6 +1,7 @@
{ pkgs, ... }:
{
systemd.services.prometheus.after = pkgs.lib.mkForce [ "network-online.target" ];
systemd.services.prometheus.wants = [ "network-online.target" ];
systemd.services.alertmanager.after = [ "prometheus.service" ];
services.prometheus = {