summaryrefslogtreecommitdiffstats
path: root/sbin/ppp-script
blob: f56ef6c6d971a9b91eef665ab4ce592f26984199 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#!/bin/sh

# Set the router for this interface
echo $1 > /tmp/$2_router

# Remove file if it exists
if [ -f /var/etc/nameserver_$2 ]; then 
	rm -f /var/etc/nameserver_$2
fi

# DNS1
if [ "$3" != "DNS0" ]; then 
	echo $3 >> /var/etc/nameserver_$2
fi

# DNS2
if [ "$4" != "DNS1" ]; then 
	echo $4 >> /var/etc/nameserver_$2
fi
OpenPOWER on IntegriCloud