gemini: Fix up DNS-313 compatible string
[openwrt/openwrt.git] / package / network / services / ppp / files / lib / netifd / ppp-up
1 #!/bin/sh
2 PPP_IPPARAM="$6"
3
4 . /lib/netifd/netifd-proto.sh
5 proto_init_update "$IFNAME" 1 1
6 proto_set_keep 1
7 [ -n "$PPP_IPPARAM" ] && {
8 [ -n "$IPLOCAL" ] && proto_add_ipv4_address "$IPLOCAL" 32 "" "${IPREMOTE:-2.2.2.2}"
9 [ -n "$IPREMOTE" ] && proto_add_ipv4_route 0.0.0.0 0 "$IPREMOTE"
10 [ -n "$DNS1" ] && proto_add_dns_server "$DNS1"
11 [ -n "$DNS2" -a "$DNS1" != "$DNS2" ] && proto_add_dns_server "$DNS2"
12 }
13 proto_send_update "$PPP_IPPARAM"
14
15 [ -d /etc/ppp/ip-up.d ] && {
16 for SCRIPT in /etc/ppp/ip-up.d/*
17 do
18 [ -x "$SCRIPT" ] && "$SCRIPT" "$@"
19 done
20 }