From 415856bdd4f48ab4f2732996f0bae58595092bbe Mon Sep 17 00:00:00 2001 From: Parabola Date: Tue, 5 Apr 2011 14:26:38 +0000 Subject: Tue Apr 5 14:26:38 UTC 2011 --- core/ppp/pon | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) create mode 100644 core/ppp/pon (limited to 'core/ppp/pon') diff --git a/core/ppp/pon b/core/ppp/pon new file mode 100644 index 000000000..36885050b --- /dev/null +++ b/core/ppp/pon @@ -0,0 +1,32 @@ +#!/bin/sh + +case "$1" in + -*) echo " +Usage: pon [provider] [arguments] + +If you specify one argument, a PPP connection will be started using +settings from the appropriate file in the /etc/ppp/peers/ directory, and +any additional arguments supplied will be passed as extra arguments to +pppd. +" + exit 0 + ;; +esac + +if [ -z "$1" -a ! -f /etc/ppp/peers/provider ]; then + echo " +Please configure /etc/ppp/peers/provider or use a command line argument to +use another file in /etc/ppp/peers/ directory. +" + exit 1 +fi + +if [ "$1" -a ! -f "/etc/ppp/peers/$1" ]; then + echo " +The file /etc/ppp/peers/$1 does not exist. +" + exit 1 +fi + +exec /usr/sbin/pppd call ${@:-provider} + -- cgit v1.2.3-54-g00ecf