aboutsummaryrefslogtreecommitdiffstats
path: root/config/tinydns/tinydns.inc
diff options
context:
space:
mode:
authorErmal <eri@pfsense.org>2010-03-29 14:32:47 +0000
committerErmal <eri@pfsense.org>2010-03-29 14:32:47 +0000
commite54cf5a0b18acb44fd85e5905147de3d50c6e36b (patch)
treeb6ffec82820165d827ab3e095715bbd94f9bab23 /config/tinydns/tinydns.inc
parentde63d61d87a69b595425eea801fd0a30d255a469 (diff)
downloadpfsense-packages-e54cf5a0b18acb44fd85e5905147de3d50c6e36b.tar.gz
pfsense-packages-e54cf5a0b18acb44fd85e5905147de3d50c6e36b.tar.bz2
pfsense-packages-e54cf5a0b18acb44fd85e5905147de3d50c6e36b.zip
Catch up with latest changes.
Diffstat (limited to 'config/tinydns/tinydns.inc')
-rw-r--r--config/tinydns/tinydns.inc20
1 files changed, 14 insertions, 6 deletions
diff --git a/config/tinydns/tinydns.inc b/config/tinydns/tinydns.inc
index de4ea302..5e730156 100644
--- a/config/tinydns/tinydns.inc
+++ b/config/tinydns/tinydns.inc
@@ -130,11 +130,17 @@ EOD;
?>
ENDPHP\n";
- $stop = <<<ENDSH
- svc -dx /var/run/service/tinydns
- /bin/rm -f /var/run/service/tinydns
- PIDTOKILL=`cat /var/run/ping_hosts.pid`
- kill \$PIDTOKILL
+ $stop = "";
+ $interfaces = explode(",", $config['installedpackages']['tinydns']['config'][0]['interface']);
+ foreach ($interfaces as $dnsidx => $dnsif)
+ $stop .= "\t/usr/local/bin/svc -dx {$g['varrun_path']}/service/dnscache{$dnsidx}\n";
+
+
+ $stop .= <<<ENDSH
+ /usr/local/bin/svc -dx {$g['varrun_path']}/service/tinydns
+ /usr/local/bin/svc -dx {$g['varrun_path']}/service/axfrdns
+ /bin/rm -rf {$g['varrun_path']}/service/tinydns {$g['varetc_path']}/tinydns {$g['varrun_path']}/dnscache* {$g['varetc_path']}/dnscache* {$g['varetc_path']}/axfrdns {$g['varrun_path']}/axfrdns
+ /bin/pkill -F /var/run/ping_hosts.pid
ENDSH;
write_rcfile(array(
@@ -153,6 +159,8 @@ function tinydns_custom_php_deinstall_command() {
conf_mount_rw();
/* destroy all daemontools items */
+ exec("/usr/local/etc/rc.d/tinydns.sh stop");
+ exec("/usr/local/etc/rc.d/svscan.sh stop");
exec("/usr/bin/killall supervise");
exec("/usr/bin/killall tinydns");
exec("/usr/sbin/pw groupdel Gtinydns");
@@ -165,7 +173,7 @@ function tinydns_custom_php_deinstall_command() {
exec("rm /usr/local/www/*tinydns*");
exec("rm /usr/local/pkg/*tinydns*");
exec("rm /usr/local/pkg/pf/*tinydns*");
- exec("rm -rf {$g['varetc_path']}/etc/tinydns {$g['varrun_path']}/service/tinydns");
+ exec("rm -rf {$g['varetc_path']}/etc/tinydns {$g['varrun_path']}/service/tinydns {$g['varetc_path']}/axfrdns");
exec("rm -rf {$g['varetc_path']}/etc/dnscache* {$g['varrun_path']}/service/dnscache*");
filter_configure();
conf_mount_ro();