From 5c9bb6f95f12741bdb5ed847e466e88039a8a4e0 Mon Sep 17 00:00:00 2001 From: Ryan Yin Date: Mon, 2 Nov 2026 01:01:28 +0800 Subject: [PATCH] chore(shoryu): drop the libvirt default-network oneshot NixOS's libvirtd-config copies default.xml but never creates its autostart link, and shoryu has no networks/autostart directory at all, so virbr0 never starts and the oneshot had nothing to disable. Assisted-by: Claude Code (claude-opus-5-5) --- hosts/12kingdoms-shoryu/libvirtd.nix | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/hosts/12kingdoms-shoryu/libvirtd.nix b/hosts/12kingdoms-shoryu/libvirtd.nix index 0a2c15df..ead17f50 100644 --- a/hosts/12kingdoms-shoryu/libvirtd.nix +++ b/hosts/12kingdoms-shoryu/libvirtd.nix @@ -39,22 +39,6 @@ in # The VMs attach to our existing bridge (br0), so allow it explicitly. virtualisation.libvirtd.allowedBridges = [ "br0" ]; - # We don't want libvirt's NAT network (virbr0): every VM uses br0. - systemd.services.libvirt-disable-default-net = { - description = "Disable libvirt's default NAT network"; - after = [ "libvirtd.service" ]; - requires = [ "libvirtd.service" ]; - wantedBy = [ "multi-user.target" ]; - serviceConfig = { - Type = "oneshot"; - RemainAfterExit = true; - }; - script = '' - ${pkgs.libvirt}/bin/virsh net-destroy default || true - ${pkgs.libvirt}/bin/virsh net-autostart --disable default || true - ''; - }; - # Define (and autostart) the declarative domains on every activation. systemd.services.libvirt-define-domains = { description = "Define the declarative libvirt domains";