diff --git a/misc/build.func b/misc/build.func index 8084e63..431eaf0 100644 --- a/misc/build.func +++ b/misc/build.func @@ -966,13 +966,6 @@ build_container() { FEATURES="$FEATURES,fuse=1" fi - if [ "$ENABLE_TUN" == "1" ]; then - cat <>"$LXC_CONFIG" -lxc.cgroup2.devices.allow: c 10:200 rwm -lxc.mount.entry: /dev/net/tun dev/net/tun none bind,create=file -EOF - fi - if [[ $DIAGNOSTICS == "yes" ]]; then post_to_api fi @@ -1066,6 +1059,13 @@ EOF fi fi + if [ "$ENABLE_TUN" == "1" ]; then + cat <>"$LXC_CONFIG" +lxc.cgroup2.devices.allow: c 10:200 rwm +lxc.mount.entry: /dev/net/tun dev/net/tun none bind,create=file +EOF + fi + # This starts the container and executes -install.sh msg_info "Starting LXC Container" pct start "$CTID"