[lxc-users] LXC containers w/ static IPs work on some hosts, not on others
Pierce Ng
pierce at samadhiweb.com
Mon Oct 24 14:19:18 UTC 2016
On Thu, Oct 20, 2016 at 02:07:09PM -0400, Michael Peek wrote:
> I started out with lxd but ran into problems when I tried googling for
> instructions on how to assign a static IP address to a container.
I set static IP for my LXD containers by configuring each container's
/etc/network/interfaces.d/50-cloud-init.cfg:
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet static
address 10.x.x.x
netmask 255.255.255.0
network 10.x.x.x
broadcast 10.x.x.x
gateway 10.x.x.x
dns-nameservers 10.x.x.x
dns-search xxx.xxx
HTH.
Pierce
More information about the lxc-users
mailing list