mediaserver: configure nameserver
This commit is contained in:
parent
f2baa135e2
commit
c07c3946a0
1 changed files with 4 additions and 0 deletions
|
@ -48,6 +48,8 @@
|
||||||
RemainAfterExit = true;
|
RemainAfterExit = true;
|
||||||
ExecStart = with pkgs; writers.writeBash "wg-up" ''
|
ExecStart = with pkgs; writers.writeBash "wg-up" ''
|
||||||
set -e
|
set -e
|
||||||
|
echo "Setting lo to up ..."
|
||||||
|
${iproute}/bin/ip -n wg link set lo up
|
||||||
echo "Creating veth bridge ..."
|
echo "Creating veth bridge ..."
|
||||||
${iproute}/bin/ip link add name vethwghost0 type veth peer name vethwgns0
|
${iproute}/bin/ip link add name vethwghost0 type veth peer name vethwgns0
|
||||||
${iproute}/bin/ip link set vethwgns0 netns wg
|
${iproute}/bin/ip link set vethwgns0 netns wg
|
||||||
|
@ -74,6 +76,8 @@
|
||||||
echo "Tearing down veth bridge ..."
|
echo "Tearing down veth bridge ..."
|
||||||
${iproute}/bin/ip -n wg link del vethwgns0
|
${iproute}/bin/ip -n wg link del vethwgns0
|
||||||
${iproute}/bin/ip link del vethwghost0
|
${iproute}/bin/ip link del vethwghost0
|
||||||
|
echo "Setting lo to down ..."
|
||||||
|
${iproute}/bin/ip -n wg link set lo down
|
||||||
echo "Done!"
|
echo "Done!"
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue