Simon Kelley | c72daea | 2012-01-05 21:33:27 +0000 | [diff] [blame] | 1 | #!/bin/sh |
| 2 | set -e |
| 3 | |
Simon Kelley | c72daea | 2012-01-05 21:33:27 +0000 | [diff] [blame] | 4 | if [ -x /etc/init.d/dnsmasq ]; then |
| 5 | update-rc.d dnsmasq defaults 15 85 >/dev/null |
| 6 | |
| 7 | if [ "$1" = "configure" ] || [ "$1" = "abort-upgrade" ]; then |
| 8 | if [ -e /var/run/dnsmasq/dnsmasq.pid ]; then |
| 9 | ACTION=restart |
| 10 | else |
| 11 | ACTION=start |
| 12 | fi |
| 13 | |
| 14 | if [ -x /usr/sbin/invoke-rc.d ] ; then |
| 15 | invoke-rc.d dnsmasq $ACTION || true |
| 16 | else |
| 17 | /etc/init.d/dnsmasq $ACTION || true |
| 18 | fi |
| 19 | fi |
| 20 | fi |
| 21 | |
Simon Kelley | c72daea | 2012-01-05 21:33:27 +0000 | [diff] [blame] | 22 | |