18 lines
445 B
Plaintext
18 lines
445 B
Plaintext
case "${ACTION}" in
|
|
post)
|
|
touch var/log/named.log
|
|
chown root:named var/log/named.log
|
|
chmod 0770 var/log/named.log
|
|
|
|
# create an rndc.key if it doesn't already exist
|
|
if [ ! -s etc/named/rndc.key ]; then
|
|
usr/sbin/rndc-confgen -r /dev/urandom -b 256 | \
|
|
head -n 5 >> etc/named/rndc.key
|
|
chown root:named etc/named/rndc.key
|
|
chmod 644 etc/named/rndc.key
|
|
fi
|
|
chown root:named etc/named/named.conf
|
|
chown -R root:named var/named
|
|
;;
|
|
esac
|