| 1 | #! /bin/bash |
| 2 | # this script automatically sets the BINDCHROOT variable to the |
| 3 | # directory that bind chroots to via configuration in |
| 4 | # /etc/default/bind9. This is only going to work if your /etc/default/bind9 |
| 5 | # is not too modified. |
| 6 | # |
| 7 | # If you want to use this magic, just uncomment it. |
| 8 | # You can also manually set the chroot directory in a non-executable |
| 9 | # file: @@define BINDCHROOT /var/cache/bind |
| 10 | |
| 11 | # # Automagically extract chroot directory |
| 12 | # . /etc/default/bind9 |
| 13 | # set $OPTIONS |
| 14 | # for i in $@;do |
| 15 | # if [ "$1" == "-t" ] |
| 16 | # then echo "@@define BINDCHROOT $2"; break |
| 17 | # else shift |
| 18 | # fi |
| 19 | # done |