I have a Pi configured as a gateway. It has its built-in br0 interface set to DHCP (eth0 being one of the members), and a br1 interface with a static IP, say 192.168.1.10/24, to serve a "private" network.
I have a bit of an issue with the case the Pi lands on a network configured the same way as the "private" network (e.g. eth0 gets a lease to 192.168.1.28/24)
Of course the "private" network I am using is not 192.168.1.0 but nonetheless a routing clash or an IP clash may happen.
I could prepare for the case the Pi is multi-homed on the same network but that would not solve the IP clash case.
I can't opportunistically change the IP of br1.
I can't think of a way an internal VLAN could help me there.
Looking around on the web I've found a guy who said he solved the issue with an LXC container, but this sounds a bit "brute force" to me.
How would you go about this?