| 1 |
Date: Mon, 06 Oct 2003 16:00:25 +0200 |
| 2 |
From: Eyal Rozenberg <[email protected]> |
| 3 |
Subject: ppp per-linkname script dir |
| 4 |
|
| 5 |
(I'm writing you as the maintainer of the Debian ppp package) |
| 6 |
|
| 7 |
On my system, I sometime find it necessary to run different commands for |
| 8 |
different peers/providers after the ppp connection, like specific |
| 9 |
complex routing configuration, etc. To do so I have added the files |
| 10 |
/etc/ppp/ip-up.d/00peer-specific and /etc/ppp/ip-down.d/00peer-specific |
| 11 |
whose contents is: |
| 12 |
------------------------------------------------------------------ |
| 13 |
|
| 14 |
#!/bin/bash |
| 15 |
# |
| 16 |
# run peer-specific (or, rather, 'link-name' specific) scripts |
| 17 |
|
| 18 |
if [ -n "$LINKNAME" ] ; then |
| 19 |
run-parts /etc/ppp/ip-up.d/$LINKNAME |
| 20 |
fi |
| 21 |
|
| 22 |
exit 0 |
| 23 |
|
| 24 |
------------------------------------------------------------------ |
| 25 |
|
| 26 |
and the same thing for if-down.d (but with its respective directory |
| 27 |
name). To use these, one must set the linkname pppd option in the files |
| 28 |
under /etc/ppp/peers - but that's a good idea anyway. |
| 29 |
|
| 30 |
Perhaps you would consider adding such files to the ppp package. |
| 31 |
|
| 32 |
Eyal Rozenberg |
| 33 |
|