diff options
author | Daniel Robbins <drobbins@gentoo.org> | 2000-12-22 01:07:26 +0000 |
---|---|---|
committer | Daniel Robbins <drobbins@gentoo.org> | 2000-12-22 01:07:26 +0000 |
commit | 3ea8cfbfd96f12402968e028d44162c538410809 (patch) | |
tree | 3ab67d14d82bfef2f9ba8f95fd3d1664fc9f43fe /net-www/squid/files | |
parent | *** empty log message *** (diff) | |
download | historical-3ea8cfbfd96f12402968e028d44162c538410809.tar.gz historical-3ea8cfbfd96f12402968e028d44162c538410809.tar.bz2 historical-3ea8cfbfd96f12402968e028d44162c538410809.zip |
a few important squid tweaks
Diffstat (limited to 'net-www/squid/files')
-rwxr-xr-x | net-www/squid/files/squid | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/net-www/squid/files/squid b/net-www/squid/files/squid index 50a1d440d407..c996447d24c3 100755 --- a/net-www/squid/files/squid +++ b/net-www/squid/files/squid @@ -10,17 +10,21 @@ PIDFILE=/var/run/squid.pid EXE=/usr/bin/squid start() { - if [ ! -d /var/cache/squid/00 ] + local cachedir + cachedir=`cat /etc/squid/squid.conf | grep '^cache_dir' | awk '{ print $3 }'` + if [ ! -d ${cachedir}/00 ] then - $EXE -z + ebegin "Initializing squid cache" + $EXE -z + eend $? "Initialized cache." "Error initializing cache." fi - ebegin "Starting $SERVICE..." + ebegin "Starting $SERVICE" start-stop-daemon --start --quiet --exec $EXE -- -sYD eend $? "Started $SERVICE." "Error Starting $SERVICE." } stop() { - ebegin "Stopping $SERVICE..." + ebegin "Stopping $SERVICE" start-stop-daemon --stop --quiet --exec $EXE eend $? "Stopped $SERVICE." "Error Stopping $SERVICE." } |