2
# adds the DNS servers got via ppp to the global resolv.conf
4
# Copyright Eddy Petrișor <eddy.petrisor@gmail.com> 2006
6
umask 0022 # normally ran by pppd with 0077
8
MARK='added by D-I (pppd)'
9
cp /etc/resolv.conf /tmp/resolv.conf.tmp
10
sed "/#$MARK/d" /tmp/resolv.conf.tmp > /etc/resolv.conf
11
rm -f /tmp/resolv.conf.tmp
12
[ "$DNS1" ] && echo "nameserver $DNS1 #$MARK" >> /etc/resolv.conf
13
[ "$DNS2" ] && echo "nameserver $DNS2 #$MARK" >> /etc/resolv.conf