This is my first encounter with LXC so this might be a silly user error, but:
I’ve set up a KVM VM with Ubuntu 16.04 LTS but for some reason the containers don’t get internet access. If I set up a container manually it works.
I installed lxc and bridge-utils on the LXC host and added a bridge, /etc/network/interfaces:
auto eth0 br0 lo
iface lo inet loopback
iface eth0 inet manual
iface br0 inet static
The LXC host has been rebooted multiple times.
If I run
sudo lxc-create -t ubuntu -n test or
sudo lxc-create -t download -n test – --dist ubuntu --release xenial --arch amd64, the networking works out of the box with the lxcbr0. I’m assuming the first one uses the templates from lxc-templates and the second one downloads it from the internet?
If I edit /etc/lxc/default.config and set
lxc.network.link = br0, the container gets a lease from my DHCP server and networking works. I get internet and can access the container from my LAN. I can also set a static IP by manually editing /var/lib/test/config and the containers interface.
I can’t get networking to work from Cloudmin either by using the precompiled Ubuntu Xenial LXC image or by using the templates. The containers show up with a status of SSH through so at least Cloudmin is able to contact them. Is there anything else that needs to be set in Cloudmin for this to work?