Different subnet on each container with same bridge

Hello im wondering if so is possible i have my lxd bridge interface giving ips on network then i could proceed in giving them a static ip but im wondering if i can put them in a different subnet without making a new bridge. ex.

you can give them what ever IP’s you want, the bridge doesn’t care as its running at layer2. You can just bind a second IP to the NIC in the container using netplan or ifupdown/ifupdown2.

I might not have explained it properly basically i have some containers on the network and other containers on network but they both get a /8 subnet from the lxd bridge so there able to talk to each other. i want the bridge to stay the way it is at a /8 and the containers at a /16 so that they are not able to talk to each other

I think your best bet would be to set up a second bridge. You could also have multiple IPs of your bridge to be able to talk to each subnets, but that would get messy real quick. At the end of the day, both /16 would need to talk to your bridge IP address to do anything useful.

i would be doing this for 30 networks… so all the way to is there a more efficient way to do this?

Use different bridges for each network as stated. To have different IP networks on the same L2 segment (bridge) is only corner-case stuff and you don’t really want to be doing that unless you really need to.

Also look into VXLAN and EVPN if your looking to slice and dice your virtual networks up en mass. FRR routing daemon will allow you to do this.