Lxc in OpenWRT

Running OpenWRT in a X86_64 machine with plenty of space. I would to have lxc in my OpenWRT. I did install luci-app-lxc and the template is empty. I have already installed kmod-veth.

Looking to get directly an IP from the OpenWRT's dhcp server, rather than being NATed to different subnet.
Any ideas how i could get my lxc into OpenWRT, please?

Can you use a tap device and attach it to the bridge?

is there a guide for LXC in Openwrt and the TAP device?

hi,

there is a guide: https://openwrt.org/lxc_openwrt_host , also you can use forum search.
but i suggest to install lxc-config & lxc-configs too.

The templates being empty was a bug that I fixed with https://github.com/openwrt/luci/pull/7104, it's only in SNAPSHOT tho so if you're running any stable release version that's why.

There are some other packages related to lxc that might come in handy. Search on my name and "lxc" to find the thread where I detail the config and how to setup. I cannot remember if I updated the wiki.

CONFIG_PACKAGE_liblxc=y
CONFIG_PACKAGE_luci-app-lxc=y
CONFIG_PACKAGE_lxc=y
CONFIG_PACKAGE_lxc-attach=y
CONFIG_PACKAGE_lxc-auto=y
CONFIG_PACKAGE_lxc-autostart=y
CONFIG_PACKAGE_lxc-cgroup=y
CONFIG_PACKAGE_lxc-common=y
CONFIG_PACKAGE_lxc-config=y
CONFIG_PACKAGE_lxc-configs=y
CONFIG_PACKAGE_lxc-console=y
CONFIG_PACKAGE_lxc-copy=y
CONFIG_PACKAGE_lxc-create=y
CONFIG_PACKAGE_lxc-destroy=y
CONFIG_PACKAGE_lxc-device=y
CONFIG_PACKAGE_lxc-execute=y
CONFIG_PACKAGE_lxc-freeze=y
CONFIG_PACKAGE_lxc-hooks=y
CONFIG_PACKAGE_lxc-info=y
CONFIG_PACKAGE_lxc-init=y
CONFIG_PACKAGE_lxc-ls=y
CONFIG_PACKAGE_lxc-snapshot=y
CONFIG_PACKAGE_lxc-start=y
CONFIG_PACKAGE_lxc-stop=y
CONFIG_PACKAGE_lxc-templates=y
CONFIG_PACKAGE_lxc-top=y
CONFIG_PACKAGE_rpcd-mod-lxc=y