Initial commit
This commit is contained in:
6
ppp/ip-down.d/000resolvconf
Executable file
6
ppp/ip-down.d/000resolvconf
Executable file
@@ -0,0 +1,6 @@
|
||||
#!/bin/sh
|
||||
# ppp.ip-down hook script for resolvconf
|
||||
# Written by Roy Marples <roy@marples.name> under the BSD-2 license
|
||||
|
||||
[ -x /sbin/resolvconf ] || exit 0
|
||||
/sbin/resolvconf -f -d "$PPP_IFACE"
|
||||
12
ppp/ip-up.d/000resolvconf
Executable file
12
ppp/ip-up.d/000resolvconf
Executable file
@@ -0,0 +1,12 @@
|
||||
#!/bin/sh
|
||||
# ppp.ip-up hook script for resolvconf
|
||||
# Written by Roy Marples <roy@marples.name> under the BSD-2 license
|
||||
|
||||
[ -x /sbin/resolvconf ] || exit 0
|
||||
|
||||
if [ -n "$DNS1" -o -n "$DNS2" ]; then
|
||||
conf="# Generated by ppp.ip-up for $PPP_IFACE\n"
|
||||
[ -n "$DNS1" ] && conf="${conf}nameserver $DNS1\n"
|
||||
[ -n "$DNS2" ] && conf="${conf}nameserver $DNS2\n"
|
||||
printf "$conf" | /sbin/resolvconf -a "$PPP_IFACE"
|
||||
fi
|
||||
Reference in New Issue
Block a user