From 7d752e987123c5e8a33d63b21a0fc50210fb9a64 Mon Sep 17 00:00:00 2001 From: Luke Granger-Brown Date: Wed, 14 Dec 2022 05:35:46 +0000 Subject: [PATCH] porcorosso: fix networkmanager bindmount --- ops/nixos/porcorosso/default.nix | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/ops/nixos/porcorosso/default.nix b/ops/nixos/porcorosso/default.nix index 8d60be318c..88e6ada0da 100644 --- a/ops/nixos/porcorosso/default.nix +++ b/ops/nixos/porcorosso/default.nix @@ -296,16 +296,18 @@ in { what = "/persist${dir}"; where = dir; }; - bindMountSvc = dir: svc: (bindMount' dir) // { + bindMountSvc = dir: svc: target: (bindMount' dir) // { bindsTo = [svc]; partOf = [svc]; + before = [svc]; + wantedBy = [target]; }; bindMount = dir: (bindMount' dir) // { wantedBy = ["multi-user.target"]; }; in [ - (bindMountSvc "/var/lib/libvirt" "libvirtd.service") - (bindMountSvc "/etc/NetworkManager/system-connections" "NetworkManager.service") + (bindMountSvc "/var/lib/libvirt" "libvirtd.service" "multi-user.target") + (bindMountSvc "/etc/NetworkManager/system-connections" "NetworkManager.service" "network.target") (bindMount "/root") ];