From 8f905ed9706c7d7c8cd617f386debafc87506097 Mon Sep 17 00:00:00 2001 From: Pranav Jerry Date: Sun, 26 Sep 2021 13:31:36 +0530 Subject: [PATCH] prepared *.net{work,dev} files to work with str.format() --- naxalnet/__init__.py | 2 +- systemd-networkd/mesh.01-batman.netdev | 2 +- systemd-networkd/mesh.02-bridge.netdev | 2 +- systemd-networkd/mesh.03-wireless-ad-hoc.network | 2 +- systemd-networkd/mesh.04-batman.network | 4 ++-- systemd-networkd/mesh.05-wireless-ap.network | 2 +- systemd-networkd/mesh.06-eth.network | 2 +- systemd-networkd/mesh.07-bridge.network | 7 ++++--- 8 files changed, 12 insertions(+), 11 deletions(-) diff --git a/naxalnet/__init__.py b/naxalnet/__init__.py index 69dfb62..8997fb4 100644 --- a/naxalnet/__init__.py +++ b/naxalnet/__init__.py @@ -35,4 +35,4 @@ See README.md for documentation. # # In case you forgot to change the version, skip the number # and put the next number in the next commit. -__version__ = "0.4.0a1" +__version__ = "0.4.0a3" diff --git a/systemd-networkd/mesh.01-batman.netdev b/systemd-networkd/mesh.01-batman.netdev index 34c1e41..025e5da 100644 --- a/systemd-networkd/mesh.01-batman.netdev +++ b/systemd-networkd/mesh.01-batman.netdev @@ -1,7 +1,7 @@ # Create the BATMAN interface # See 04-batman.network for configuration details [NetDev] -Name=bat0 +Name={batdev} Description=BATMAN interface Kind=batadv diff --git a/systemd-networkd/mesh.02-bridge.netdev b/systemd-networkd/mesh.02-bridge.netdev index b7d5cf6..2ca6a58 100644 --- a/systemd-networkd/mesh.02-bridge.netdev +++ b/systemd-networkd/mesh.02-bridge.netdev @@ -2,7 +2,7 @@ # The batman interface be will later linked to this bridge. # See 07-bridge.network to see how this bridge is configured [NetDev] -Name=bridge0 +Name={bridgedev} Description=Bridge Kind=bridge diff --git a/systemd-networkd/mesh.03-wireless-ad-hoc.network b/systemd-networkd/mesh.03-wireless-ad-hoc.network index b0019ae..0db3344 100644 --- a/systemd-networkd/mesh.03-wireless-ad-hoc.network +++ b/systemd-networkd/mesh.03-wireless-ad-hoc.network @@ -10,7 +10,7 @@ MTUBytes=1560 [Network] Description=ad-hoc network connecting to other nodes -BatmanAdvanced=bat0 +BatmanAdvanced={batdev} # This interface should not have any IP addresses assigned. # IP will be given later to the bridge DHCP=no diff --git a/systemd-networkd/mesh.04-batman.network b/systemd-networkd/mesh.04-batman.network index 9eba2c6..f835808 100644 --- a/systemd-networkd/mesh.04-batman.network +++ b/systemd-networkd/mesh.04-batman.network @@ -1,9 +1,9 @@ [Match] -Name=bat0 +Name={batdev} [Network] Description=The BATMAN interface -Bridge=bridge0 +Bridge={bridgedev} # like in 03-wireless-ad-hoc.network, this interface # also shouldn't have IP address the address will diff --git a/systemd-networkd/mesh.05-wireless-ap.network b/systemd-networkd/mesh.05-wireless-ap.network index 0b35dae..25278e1 100644 --- a/systemd-networkd/mesh.05-wireless-ap.network +++ b/systemd-networkd/mesh.05-wireless-ap.network @@ -11,7 +11,7 @@ WLANInterfaceType=ap Description=Wireless AP # link the interface to the bridge -Bridge=bridge0 +Bridge={bridgedev} # Like in the ad-hoc network and bat0, this interface # should not have any ip address assigned to it. diff --git a/systemd-networkd/mesh.06-eth.network b/systemd-networkd/mesh.06-eth.network index 0c81f21..3e27b9a 100644 --- a/systemd-networkd/mesh.06-eth.network +++ b/systemd-networkd/mesh.06-eth.network @@ -5,4 +5,4 @@ Name=en* Name=eth* [Network] -Bridge=bridge0 +Bridge={bridgedev} diff --git a/systemd-networkd/mesh.07-bridge.network b/systemd-networkd/mesh.07-bridge.network index 1c14c70..6214a9d 100644 --- a/systemd-networkd/mesh.07-bridge.network +++ b/systemd-networkd/mesh.07-bridge.network @@ -3,13 +3,14 @@ # communicate with others devices [Match] -Name=bridge0 +Name={bridgedev} [Network] -# use DHCP to assign an IP +# Use DHCP to assign an IP DHCP=yes -# if DHCP fails, assign a random address +# If DHCP fails, assign a random address. This is probably the default, +# but we are specifying it anyway. LinkLocalAddressing=yes # LLMNR and MulticastDNS are used for hostname discovery