Bug 129452

Summary: wwwoffle doesn't work "out of the package" for dial-in connections
Product: [openSUSE] SUSE LINUX 10.0 Reporter: Martin Jost <lists>
Component: NetworkAssignee: Mads Martin Joergensen <mmj>
Status: RESOLVED FIXED QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None    
Version: Final   
Target Milestone: ---   
Hardware: i686   
OS: SuSE Linux 10.0   
Whiteboard:
Found By: Other Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description Martin Jost 2005-10-19 17:41:58 UTC
While wwwoffle is included as rpm-package it requiered manual action to get it
to work.
The problem is, that wwwoffle doesn't get notified, when the network connection
is build up or teared down. (wwwoffle -online / wwwoffle -offline)

Solution:
I got this solved by putting this as "wwwoffle" in /etc/ppp/ip-up.d
--- snip, snip ---
if [ -x /usr/bin/wwwoffle ]; then
   # Restart to notify of new DNS (is there a better solution ?)
   /etc/rc.d/wwwoffle stop
   /etc/rc.d/wwwoffle start

   # Set the WWWOFFLE HTTP proxy server online.
   /usr/bin/wwwoffle -online -c /etc/wwwoffle/wwwoffle.conf

   # Get the WWWOFFLE HTTP proxy server to fetch requested URLs.
   /usr/bin/wwwoffle -fetch -c /etc/wwwoffle/wwwoffle.conf &
fi
------ snip, snip ----------

And this in /etc/ppp/ip-down.d
------ snip, snip ----------
# Set the WWWOFFLE HTTP proxy server offline.
if [ -x /usr/bin/wwwoffle ]; then
   /usr/bin/wwwoffle -offline -c /etc/wwwoffle/wwwoffle.conf
fi


# Index WWWOFFLE-Cache in Background
umask 022
/var/spool/wwwoffle/search/htdig/scripts/wwwoffle-htdig-full &

# Leaves Log-File in
# /var/spool/wwwoffle/search/htdig/wwwoffle-htdig.log
------ snip, snip ----------

Note: The index part is related to htdig.
Comment 1 Mads Martin Joergensen 2005-10-21 17:55:05 UTC
I've added the two scripts to /etc/ppp/if-{up,down}.d/

Thanks for the input!