Fossil is a single executable with low system requirements operating on a single SQLite database file, so it's really easy to chroot. It'll even chroot itself if started as root: https://www.fossil-scm.org/home/doc/trunk/www/chroot.md
If you want something more complicated (BSD jails, Docker, etc.) the same properties make it easy to box up that way instead.