diff options
author | Leon Woestenberg <leon.woestenberg@gmail.com> | 2008-05-23 15:59:49 +0000 |
---|---|---|
committer | Leon Woestenberg <leon.woestenberg@gmail.com> | 2008-05-23 15:59:49 +0000 |
commit | 33b90e2dbb1f21ba4511f3e85dfeab1ae24502c4 (patch) | |
tree | 04b505d6d032b8fb91eb9772a57fb0c5e5f393e8 /packages/wwwoffle/files/wwwoffle.if-up | |
parent | ef71e5fbb312339650882401b54739a5e60726fc (diff) | |
parent | df42d84d1ac1fc35e56fa66cf6559ce6ca2893d3 (diff) |
merge of '5135d5b0b85d509b8af80d221f18563d4ce62475'
and '8b21a69e52feb768f1d096aa78e44dd20ce3aed4'
Diffstat (limited to 'packages/wwwoffle/files/wwwoffle.if-up')
-rw-r--r-- | packages/wwwoffle/files/wwwoffle.if-up | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/packages/wwwoffle/files/wwwoffle.if-up b/packages/wwwoffle/files/wwwoffle.if-up new file mode 100644 index 0000000000..43167a9e9c --- /dev/null +++ b/packages/wwwoffle/files/wwwoffle.if-up @@ -0,0 +1,36 @@ +#!/bin/sh + +# We want to run wwwoffle only for selected interfaces: +# Maybe better would be checking of the default route. +case "$IFACE" in + wlan*) + ;; + eth*) + ;; + usb*) + ;; + ppp*) + ;; + *) + exit 0 + ;; +esac + +# wwwoffle caches old network configuration and it may cause resolve failures +/usr/bin/wwwoffle -kill +/usr/sbin/wwwoffled >/dev/null 2>&1 + +/usr/bin/wwwoffle -online + +# Don't fetch over ppp*, which is typically expensive dial-up. +# Comment out, if you want to fetch pre-ordered pages over GPRS, dial-up or so. +case "$IFACE" in + ppp*) + exit 0 + ;; +esac + +# Fetch may take longer time. Run it in background +( /usr/bin/wwwoffle -fetch ) & + +exit |