Working with DTC inside a jail

Hello all,

I've been trying to clean up some of the DTC installer script (http://www.gplhost.com/software-dtc.html) to make it a bit easier to get running on FreeBSD. The project is one of the nicer open source control panels I've found so far.

One thing I'm having trouble working around is making device nodes inside a jail. DTC has a chroot shell for those that wish to provide shell access to their hosting customers, and since it has a hierarchy of user perms for these users, there is a full set of chroot binaries, devices, etc. up and down a customer's filespace. Each instance of this chroot skeleton needs some basic device nodes created (random, null, etc.).

In a jail, this isn't allowed...

Are there any other options other than something hackish like a cron job outside the jail calling a script that walks the hierarchy and does the proper mknods if they don't yet exist? I'd also like to avoid devfs, since I could easily end up with hundreds of devfs mounts to manage. :)
 
Maybe doing your cleanup work inside a jail is the wrong place to be doing it. If it suppose to run on the host then clean it up on the host.
 
SirDice said:
You can't avoid devfs. Device nodes are created on the fly. The are not created with mknod. See devfs(8) and devfs.rules(5).

I did use mknod to create a few test nodes. They work fine.

I understand the limitations here, just looking for any alternatives that I might not have ruled out already. :)

All I'm left with is doing this outside the jail, which works fine for me, but isn't something I can take back to the DTC project - they do want to deploy in jails (and other than this, which is a pretty minor feature) it's working great. So far this is the only open source web control panel that comes close to working out of the box on FreeBSD, so I'm quite eager to help. The gap is not too huge here, the DTC devs are all Debian folk, so we do nearly talk the same language...
 
Back
Top