Implement simple network bridge

This commit is contained in:
Simon Fels 2016-11-26 13:38:38 +01:00
commit 06b529e0a0
3 changed files with 235 additions and 0 deletions

View file

@ -106,6 +106,10 @@ void LxcContainer::start(const Configuration &configuration) {
set_config_item("lxc.loglevel", "0");
set_config_item("lxc.logfile", utils::string_format("%s/container.log", config::log_path()).c_str());
set_config_item("lxc.network.type", "veth");
set_config_item("lxc.network.flags", "up");
set_config_item("lxc.network.link", "anboxbr0");
#if 0
// Android uses namespaces as well so we have to allow nested namespaces for LXC
// which are otherwise forbidden by AppArmor.