8.11 Running Tinderbox in a Jail

Tinderbox can be run in a FreeBSD jail with some concessions.

Since neither NFS nor nullfs (at the time of writing) are usable in a jail, we cannot simply install and use as normal. Instead, we simply use a chroot.

  1. Create a jail for your Tinderbox using the instructions in the FreeBSD Handbook.

  2. Install dependencies into the jail (Chapter 2).

  3. Install Tinderbox (in the jail):

    # mkdir ${pb}
    # cd ${pb} && \
      fetch -o - path_to_tinderbox-4.2.0.tar.gz | \
      tar xvf -
  4. Now we need to leave the jail, and on the host system chroot into it:

    # chroot ${jail_dir} /bin/csh

    Now follow from step 3 in Chapter 3.

  5. Copy ${jail_dir}/${pb}/scripts/etc/rc.d/tinderd to /usr/local/etc/rc.d/

  6. Add the following lines to /etc/rc.conf (again, in the host system):

    tinderd_enable="YES"
    tinderd_chroot="${jail_dir}"
    tinderd_directory="${pb}"
    tinderd_flags="-nullfs"
  7. Install a web server of your choice in the jail, and follow the webserver setup.

All administration and use of the Tinderbox must now be done from the host system, by using chroot into ${jail_dir}.