From c07c3946a01c8c9d20a237e427c8706e039584dc Mon Sep 17 00:00:00 2001 From: Daniel Kempkens Date: Wed, 19 Apr 2023 01:33:58 +0200 Subject: [PATCH] mediaserver: configure nameserver --- system/nixos/wireguard-netns.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/system/nixos/wireguard-netns.nix b/system/nixos/wireguard-netns.nix index f68b62d..5b897ef 100644 --- a/system/nixos/wireguard-netns.nix +++ b/system/nixos/wireguard-netns.nix @@ -48,6 +48,8 @@ RemainAfterExit = true; ExecStart = with pkgs; writers.writeBash "wg-up" '' set -e + echo "Setting lo to up ..." + ${iproute}/bin/ip -n wg link set lo up echo "Creating veth bridge ..." ${iproute}/bin/ip link add name vethwghost0 type veth peer name vethwgns0 ${iproute}/bin/ip link set vethwgns0 netns wg @@ -74,6 +76,8 @@ echo "Tearing down veth bridge ..." ${iproute}/bin/ip -n wg link del vethwgns0 ${iproute}/bin/ip link del vethwghost0 + echo "Setting lo to down ..." + ${iproute}/bin/ip -n wg link set lo down echo "Done!" ''; };