Nixos in a container truenas 26 beta 1

Any one running into issues running nixos inside an lxc (containers) with Truenas 26 Beta 1 ?

While trying to manage the container through the shell in the truenas UI I receive the following error

nsenter: failed to execute capsh: No such file or directory.

I also tried to install a fresh nixos container and the same error happens.

In addition inside the container I was running nebula vpn, however now it seems the container does not have permissions to access the /dev/net/tun adapter.

Could this be a default permissions issue with mapping UID/GIDs ?

Thanks,

You may need to run it as a privileged container? https://www.truenas.com/docs/scale/26/containers/managingcontainers/#running-nested-containers

This is a known issue related to how UI shell works in BETA1 (it relied on assumption that capsh was available in container). Being addressed for BETA2. The bug was reported regarding alpine linux, but this sounds much the same.

1 Like

Ah you’re right. And I was the reporter on that issue :sweat_smile:

I also want to access /dev/net/tun adapter within a container. This is to run a privileged Debian LXC container for installing podman and Unifi OS Server. I can install podman, but Unifi OS Server requires access to /dev/net/tun on the host. I don’t see a way to map a passthrough of /dev/net/tun from the host to the container using the TrueNAS 26 Beta 1 UI.

1 Like