People don't seem to use them on Linux for containers, but on FreeBSD that was the way to set up IP addresses for jails. You just had tons of aliases on an interface and you gave these IPs to jails. Anything that binds to 0.0.0.0 inside a jail gets bound to the jail's IP.
Now you can use VNET/VIMAGE to give jails separate virtual network interfaces. If you want to. The option to use aliases is still there of course.
Now you can use VNET/VIMAGE to give jails separate virtual network interfaces. If you want to. The option to use aliases is still there of course.