[lxc-users] Need help with static IP address -- Simplest use case.

Michael Johnson johnson at cognitech-ut.com
Sat Jun 10 06:29:17 UTC 2017


Here is the magic command:

lxc config device add gentoo default nic nictype=bridged name=eth0
parent=br0 ipv4.address=192.168.0.36/24 ipv6.address=none

Issue that after configuring eth0 in the container to have the same
static ip, and configuring a host bridge br0.

No 'lxc network create' nor 'lxc network attach' is needed.

I hope someone else finds this useful.

-Mike



More information about the lxc-users mailing list