summaryrefslogtreecommitdiffstats
path: root/tv/2configs/xu-qemu0.nix
diff options
context:
space:
mode:
authortv <tv@krebsco.de>2016-02-13 20:55:38 +0100
committertv <tv@krebsco.de>2016-02-13 20:59:54 +0100
commit230c8088c8e96a990400533c780b035c8a4102de (patch)
treef3016a6a35399bf5404965b3e1dccd44a5b6f589 /tv/2configs/xu-qemu0.nix
parentca246b6994950cf45aeb69e6e2e4c8f40fda7aa2 (diff)
xu-qemu0: setup qemubr0 address and route
Diffstat (limited to 'tv/2configs/xu-qemu0.nix')
-rw-r--r--tv/2configs/xu-qemu0.nix28
1 files changed, 13 insertions, 15 deletions
diff --git a/tv/2configs/xu-qemu0.nix b/tv/2configs/xu-qemu0.nix
index 205b1c011..4d39031db 100644
--- a/tv/2configs/xu-qemu0.nix
+++ b/tv/2configs/xu-qemu0.nix
@@ -15,33 +15,31 @@ in
#
# make [install] system=xu-qemu0 target_host=10.56.0.101
-# TODO iptables -A INPUT -p udp -m udp --dport bootps -j ACCEPT
+# TODO iptables -A FORWARD -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT
# TODO iptables -A FORWARD -i qemubr0 -s 10.56.0.1/24 -m conntrack --ctstate NEW -j ACCEPT
# TODO iptables -A POSTROUTING -t nat -j MASQUERADE
-# TODO iptables -A FORWARD -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT
+# TODO iptables -A INPUT -i qemubr0 -p udp -m udp --dport bootps -j ACCEPT
# TODO iptables -A INPUT -i qemubr0 -p udp -m udp --dport domain -j ACCEPT
# TODO echo 1 > /proc/sys/net/ipv4/ip_forward
-# TODO ifconfig qemubr0 10.56.0.1/24 up
with lib;
{
- #networking.wireless.interfaces = [ "wlp3s0" ];
-
- #networking.useNetworkd = true;
-
- #networking.dhcpcd.allowInterfaces = [
- # "qemubr0"
- #];
-
- #systemd.network.networks.wlp3s0 = {
- # matchConfig.name = "wlp3s0";
- # networkConfig.Bridge = "qemubr0";
- #};
+ networking.dhcpcd.denyInterfaces = [ "qemubr0" ];
systemd.network.enable = true;
services.resolved.enable = mkForce false;
+ systemd.network.networks.qemubr0 = {
+ matchConfig.Name = "qemubr0";
+ address = ["10.56.0.1/24"];
+ routes = [{
+ routeConfig = {
+ Gateway = "*";
+ Destination = "10.56.0.0";
+ };
+ }];
+ };
systemd.network.netdevs.qemubr0 = {
netdevConfig = {
Name = "qemubr0";