Skip to content

Instantly share code, notes, and snippets.

@viq
Last active January 1, 2018 15:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save viq/f8b69adb292fd0f20de264a10bf5c0b3 to your computer and use it in GitHub Desktop.
Save viq/f8b69adb292fd0f20de264a10bf5c0b3 to your computer and use it in GitHub Desktop.
LXC configs
lxc.net.0.type = veth
lxc.net.0.link = virbr0
lxc.net.0.flags = up
lxc.net.0.hwaddr = 00:16:3e:xx:xx:xx
lxc.container_profile:
centos:
template: centos
backing: lvm
vgname: LVM
lvname: lxclv
size: 10G
archlinux:
template: archlinux
backing: lvm
vgname: LVM
lvname: lxclv
size: 10G
lxc.network_profile:
centos:
eth0:
link: virbr0
type: veth
flags: up
archlinux:
eth0:
link: virbr0
type: veth
flags: up
lxc.net.0.type = veth
lxc.net.0.link = virbr0
lxc.net.0.flags = up
lxc.net.0.hwaddr = 00:16:3e:12:14:6a
lxc.rootfs.path = dir:/var/lib/lxc/test1/rootfs
lxc.uts.name = test1
lxc.arch = x86_64
lxc.include = /usr/share/lxc/config/archlinux.common.conf
lxc.net.0.type = veth
lxc.net.0.link = virbr0
lxc.net.0.flags = up
lxc.net.0.hwaddr = 00:16:3e:12:14:6a
lxc.rootfs.path = dir:/var/lib/lxc/test1/rootfs
lxc.uts.name = test1
lxc.arch = x86_64
lxc.include = /usr/share/lxc/config/archlinux.common.conf
lxc.start.auto = 1
lxc.network.type = veth
lxc.network.name = eth0
lxc.network.flags = up
lxc.network.link = lxcbr0
lxc.network.hwaddr = AC:DE:48:65:F6:74
@viq
Copy link
Author

viq commented Jan 1, 2018

sudo lxc-create -n test -t /usr/share/lxc/templates/lxc-archlinux gives me a container with working network.
sudo salt-call -l debug --local lxc.init test1 profile=archlinux template=archlinux bridge=virbr0 gives me container with no network.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment