|
@ -87,16 +87,29 @@ do_connect() { |
|
|
rm -f $DNSMASQ_FILE |
|
|
rm -f $DNSMASQ_FILE |
|
|
echo "$SDNS" | while read i; do |
|
|
echo "$SDNS" | while read i; do |
|
|
if [ -n "$INTERNAL_IP4_DNS" ];then |
|
|
if [ -n "$INTERNAL_IP4_DNS" ];then |
|
|
echo "server=/$i/$INTERNAL_IP4_DNS" >> $DNSMASQ_FILE |
|
|
|
|
|
|
|
|
for dns in "$INTERNAL_IP4_DNS";do |
|
|
|
|
|
echo "server=/$i/$dns" >> $DNSMASQ_FILE |
|
|
|
|
|
done |
|
|
fi |
|
|
fi |
|
|
if [ -n "$INTERNAL_IP6_DNS" ];then |
|
|
if [ -n "$INTERNAL_IP6_DNS" ];then |
|
|
echo "server=/$i/$INTERNAL_IP6_DNS" >> $DNSMASQ_FILE |
|
|
|
|
|
|
|
|
for dns in "$INTERNAL_IP6_DNS";do |
|
|
|
|
|
echo "server=/$i/$dns" >> $DNSMASQ_FILE |
|
|
|
|
|
done |
|
|
fi |
|
|
fi |
|
|
echo "rebind-domain-ok=$i" >> $DNSMASQ_FILE |
|
|
echo "rebind-domain-ok=$i" >> $DNSMASQ_FILE |
|
|
done |
|
|
done |
|
|
/etc/init.d/dnsmasq restart |
|
|
/etc/init.d/dnsmasq restart |
|
|
else |
|
|
else |
|
|
[ -n "$INTERNAL_IP4_DNS" ] && proto_add_dns_server "$INTERNAL_IP4_DNS" |
|
|
|
|
|
|
|
|
if [ -n "$INTERNAL_IP4_DNS" ];then |
|
|
|
|
|
for dns in "$INTERNAL_IP4_DNS";do |
|
|
|
|
|
proto_add_dns_server "$dns" |
|
|
|
|
|
done |
|
|
|
|
|
fi |
|
|
|
|
|
if [ -n "$INTERNAL_IP6_DNS" ];then |
|
|
|
|
|
for dns in "$INTERNAL_IP6_DNS";do |
|
|
|
|
|
proto_add_dns_server "$dns" |
|
|
|
|
|
done |
|
|
|
|
|
fi |
|
|
[ -n "$CISCO_DEF_DOMAIN" ] && proto_add_dns_search "$CISCO_DEF_DOMAIN" |
|
|
[ -n "$CISCO_DEF_DOMAIN" ] && proto_add_dns_search "$CISCO_DEF_DOMAIN" |
|
|
fi |
|
|
fi |
|
|
|
|
|
|
|
|