diff options
author | Martin Wilke <miwi@FreeBSD.org> | 2010-05-02 10:53:14 +0000 |
---|---|---|
committer | Martin Wilke <miwi@FreeBSD.org> | 2010-05-02 10:53:14 +0000 |
commit | 9fa7e5f5e4559b74ade6b2373d4f5b553b175bae (patch) | |
tree | 31ba8d986ae748f81ae6be46b748fe073c1373e3 /www/squid31 | |
parent | f6eb936232e87c8966c85e907da2f78d90a5357b (diff) | |
download | ports-9fa7e5f5e4559b74ade6b2373d4f5b553b175bae.tar.gz ports-9fa7e5f5e4559b74ade6b2373d4f5b553b175bae.zip |
- Update MASTER_SITES
- Move default cache and log directories from $PREFIX/squid/ to /var/squid/
PR: 145675
Submitted by: Thomas-Martin Seck <tmseck@web.de> (maintainer)
Notes
Notes:
svn path=/head/; revision=253545
Diffstat (limited to 'www/squid31')
-rw-r--r-- | www/squid31/Makefile | 63 | ||||
-rw-r--r-- | www/squid31/distinfo | 6 | ||||
-rw-r--r-- | www/squid31/files/pkg-deinstall.in | 13 | ||||
-rw-r--r-- | www/squid31/files/pkg-install.in | 29 | ||||
-rw-r--r-- | www/squid31/files/pkg-message.in | 16 | ||||
-rw-r--r-- | www/squid31/files/squid.in | 8 | ||||
-rw-r--r-- | www/squid31/pkg-descr | 3 |
7 files changed, 69 insertions, 69 deletions
diff --git a/www/squid31/Makefile b/www/squid31/Makefile index c61ceb825f10..b9de7642ea33 100644 --- a/www/squid31/Makefile +++ b/www/squid31/Makefile @@ -52,46 +52,45 @@ # Do not support loadable modules. PORTNAME= squid -PORTVERSION= 3.1.0.${SQUID_BETA_VER} +PORTVERSION= 3.1.${SQUID_STABLE_VER} CATEGORIES= www ipv6 MASTER_SITES= ftp://ftp.squid-cache.org/pub/%SUBDIR%/ \ - ftp://mirrors.24-7-solutions.net/pub/squid/%SUBDIR%/ \ - ftp://ftp.belnet.be/packages/squid/pub/%SUBDIR%/ \ - ftp://ftp.nl.uu.net/pub/unix/www/squid/%SUBDIR%/ \ - ftp://ftp.mirrorservice.org/sites/ftp.squid-cache.org/pub/%SUBDIR%/ \ - ftp://ftp.ntua.gr/pub/www/Squid/%SUBDIR%/ \ - ftp://ftp.ccs.neu.edu/pub/mirrors/squid.nlanr.net/pub/%SUBDIR%/ \ - ${MASTER_SITE_RINGSERVER:S,%SUBDIR%,net/www/squid/&,} \ + http://mirrors.ccs.neu.edu/Squid/ \ + ftp://ftp.fu-berlin.de/unix/www/squid/squid/ \ + ftp://ftp.nl.uu.net/pub/unix/www/squid/ \ + ftp://ftp.solnet.ch/mirror/squid/ \ + ftp://ftp.ntua.gr/pub/www/Squid/squid/ \ + http://mirror.aarnet.edu.au/pub/squid/squid/ \ + ${MASTER_SITE_RINGSERVER:S,%SUBDIR%,net/www/squid,} \ http://www.squid-cache.org/Versions/v3/3.1/ \ - http://www3.us.squid-cache.org/Versions/v3/3.1/ \ + http://www2.us.squid-cache.org/Versions/v3/3.1/ \ http://www1.at.squid-cache.org/Versions/v3/3.1/ \ - http://www2.nl.squid-cache.org/Versions/v3/3.1/ \ - http://www1.ru.squid-cache.org/Versions/v3/3.1/ \ - http://www1.uk.squid-cache.org/Versions/v3/3.1/ \ + http://www2.de.squid-cache.org/Versions/v3/3.1/ \ + http://www.eu.squid-cache.org/Versions/v3/3.1/ \ + http://www1.ie.squid-cache.org/Versions/v3/3.1/ \ http://www1.jp.squid-cache.org/Versions/v3/3.1/ \ http://www2.tw.squid-cache.org/Versions/v3/3.1/ MASTER_SITE_SUBDIR= squid -DISTNAME= squid-3.1.0.${SQUID_BETA_VER} +DISTNAME= squid-3.1.${SQUID_STABLE_VER} DIST_SUBDIR= squid3.1 PATCH_SITES= http://www.squid-cache.org/%SUBDIR%/ \ http://www2.us.squid-cache.org/%SUBDIR%/ \ - http://www3.us.squid-cache.org/%SUBDIR%/ \ http://www1.at.squid-cache.org/%SUBDIR%/ \ - http://www2.nl.squid-cache.org/%SUBDIR%/ \ - http://www1.ru.squid-cache.org/%SUBDIR%/ \ - http://www1.uk.squid-cache.org/%SUBDIR%/ \ + http://www2.de.squid-cache.org/%SUBDIR%/ \ + http://www.eu.squid-cache.org/%SUBDIR%/ \ + http://www1.ie.squid-cache.org/%SUBDIR%/ \ http://www1.jp.squid-cache.org/%SUBDIR%/ \ - http://www1.tw.squid-cache.org/%SUBDIR%/ + http://www2.tw.squid-cache.org/%SUBDIR%/ PATCH_SITE_SUBDIR= Versions/v3/3.1/changesets PATCHFILES= MAINTAINER= tmseck@web.de -COMMENT= HTTP Caching Proxy (BETA Version) +COMMENT= HTTP Caching Proxy LATEST_LINK= squid31 -SQUID_BETA_VER= 17 +SQUID_STABLE_VER= 1 CONFLICTS= squid-2.[0-9].* squid-3.[^1].* cacheboy-[0-9]* lusca-head-[0-9]* GNU_CONFIGURE= yes @@ -177,7 +176,7 @@ error_files= ERR_ACCESS_DENIED ERR_CACHE_ACCESS_DENIED \ ERR_URN_RESOLVE ERR_WRITE_ERROR ERR_ZERO_SIZE_OBJECT error_dirs= af ar az bg ca cs da de el en es et fa fi fr he hu hy id it \ - ja ko lt lv ms nl pl pt pt-br ro ru sk sr sv th tr uk uz \ + ja ko lt lv ms nl pl pt pt-br ro ru sk sv th tr uk uz \ zh-cn zh-tw \ templates @@ -196,7 +195,7 @@ error_dir_links= ar-ae ar-bh ar-dz ar-eg ar-iq ar-jo ar-kw ar-lb \ fr-be fr-ca fr-ch fr-fr fr-lu fr-mc \ he-il hu-hu hy-am id-id it-ch it-it \ ja-jp ko-kp ko-kr lt-lt lv-lv ms-my nl-nl \ - pl-pl pt-pt ro-md ro-ro ru-ru sk-sk sr-sp sv-fi sv-se \ + pl-pl pt-pt ro-md ro-ro ru-ru sk-sk sv-fi sv-se \ th-th tr-tr uk-ua zh-hk zh-mo zh-sg libexec= cachemgr.cgi digest_pw_auth diskd ip_user_check \ @@ -209,27 +208,15 @@ libexec+= unlinkd sbin= squidclient squid -# XXX: -# Squid 3.1 changed the default for the pid file location from -# ${localstatedir}/logs/squid.pid to ${localstatedir}/squid.pid. -# -# There are two ways to tackle this: -# 1) enforce the old default using --with-pidfile=${PREFIX}/squid/logs/squid.pid -# 2) accept the new default (and hardwire it here as well) and make sure -# that ${localstatedir} is writable by the Squid master process. (It -# used not to be, unless the Squid master process had root privileges -# or ${localstatedir}'s ACL is modified (chgrp squid; chmod g+w).) -# This is what we do now, see also files/pkg-install.in. - CONFIGURE_ARGS= --with-default-user=${SQUID_UID} \ --bindir=${PREFIX}/sbin \ --sbindir=${PREFIX}/sbin \ --datadir=${PREFIX}/etc/squid \ --libexecdir=${PREFIX}/libexec/squid \ - --localstatedir=${PREFIX}/squid \ + --localstatedir=/var/squid \ --sysconfdir=${PREFIX}/etc/squid \ - --with-logdir=${PREFIX}/squid/logs \ - --with-pidfile=${PREFIX}/squid/squid.pid \ + --with-logdir=/var/log/squid \ + --with-pidfile=/var/run/squid/squid.pid \ --enable-removal-policies="lru heap" \ --disable-linux-netfilter \ --disable-linux-tproxy \ @@ -435,7 +422,7 @@ PLIST_DIRS+= etc/squid/errors/${d} PLIST_FILES+= ${error_files:S,^,etc/squid/errors/${d}/,} .endfor PLIST_FILES+= ${error_dir_links:S,^,etc/squid/errors/,} -PLIST_DIRS+= etc/squid/errors etc/squid squid/logs squid/cache squid +PLIST_DIRS+= etc/squid/errors etc/squid post-patch: @${REINPLACE_CMD} -e 's|%%PREFIX%%|${PREFIX}|g' \ diff --git a/www/squid31/distinfo b/www/squid31/distinfo index a187e26d135b..363cf5154f09 100644 --- a/www/squid31/distinfo +++ b/www/squid31/distinfo @@ -1,3 +1,3 @@ -MD5 (squid3.1/squid-3.1.0.17.tar.bz2) = 5acabbc26f52363389703a8ce510c88d -SHA256 (squid3.1/squid-3.1.0.17.tar.bz2) = 1ea00fe852370cfa1b1b26d02526e8a61716243081e6488c29e586df0b7dd770 -SIZE (squid3.1/squid-3.1.0.17.tar.bz2) = 2383810 +MD5 (squid3.1/squid-3.1.1.tar.bz2) = 4316f396d9134049c775c16dc5cf297c +SHA256 (squid3.1/squid-3.1.1.tar.bz2) = e61fa87631bab41257295b6be010b72f8a1a8961aac2197256d87cf0be7e3081 +SIZE (squid3.1/squid-3.1.1.tar.bz2) = 2385027 diff --git a/www/squid31/files/pkg-deinstall.in b/www/squid31/files/pkg-deinstall.in index 5ec2fe766068..f78c66c178bd 100644 --- a/www/squid31/files/pkg-deinstall.in +++ b/www/squid31/files/pkg-deinstall.in @@ -4,13 +4,22 @@ # PATH=/bin:/usr/bin:/usr/sbin +squid_base="/var/squid" +squid_cachedir="${squid_base}/cache" +squid_confdir=${PKG_PREFIX}/etc/squid +squid_logdir="/var/log/squid" +squid_rundir="/var/run/squid" case $2 in DEINSTALL) - cd ${PKG_PREFIX}/etc/squid || exit 1 + cd ${squid_confdir} || exit 1 for f in cachemgr.conf errorpage.css mime.conf msntauth.conf squid.conf; do cmp -s -z ${f} ${f}.default && rm ${f} done + # try to cleanup directories in /var: + for d in ${squid_cachedir} ${squid_base} ${squid_logdir} ${squid_rundir}; do + rmdir ${d} 2>/dev/null + done ;; POST-DEINSTALL) echo "===> post-deinstallation information for $1:" @@ -22,7 +31,7 @@ POST-DEINSTALL) echo " created by a default installation of this package, run" echo "" echo " pw userdel -n %%SQUID_UID%% -u 100" - if [ -d ${PKG_PREFIX}/squid -o -d ${PKG_PREFIX}/etc/squid ] ; then + if [ -d ${squid_base} -o -d ${squid_confdir} -o -d ${squid_logdir} -o -d ${squid_rundir} ] ; then echo "" echo " In order to ease updates the cache and log directories" echo " and all configuration files modified by you were preserved." diff --git a/www/squid31/files/pkg-install.in b/www/squid31/files/pkg-install.in index 1a8391765789..2ab8d99dc70f 100644 --- a/www/squid31/files/pkg-install.in +++ b/www/squid31/files/pkg-install.in @@ -5,8 +5,11 @@ PATH=/bin:/usr/bin:/usr/sbin pkgname=$1 -squid_base="${PKG_PREFIX:-%%PREFIX%%}/squid" +squid_base="/var/squid" +squid_cachedir="${squid_base}/cache" squid_confdir="${PKG_PREFIX:-%%PREFIX%%}/etc/squid" +squid_logdir="/var/log/squid" +squid_rundir="/var/run/squid" if [ -x /usr/sbin/nologin ]; then nologin=/usr/sbin/nologin else @@ -50,10 +53,8 @@ PRE-INSTALL) echo "I will use the existing user '${squid_user}':" fi pw usershow ${squid_user} - # Starting with 3.1, Squid's PID file moved from - # ${squid_base}/logs/squid.pid to ${squid_base}/squid.pid. - # Since we usually start the Squid master process as ${squid_user}, - # make sure that ${squid_base} is writable for it. + # Since we usually start the Squid master process as ${squid_user} + # instead of root make sure that ${squid_base} is writable for it. if [ ! -d ${squid_base} ]; then echo "Creating ${squid_base}..." install -d -o root -g ${squid_group} \ @@ -62,18 +63,26 @@ PRE-INSTALL) chgrp ${squid_group} ${squid_base} chmod g+w ${squid_base} fi - for dir in cache logs; do - if [ ! -d ${squid_base}/${dir} ]; then - echo "Creating ${squid_base}/${dir}..." + if [ ! -d ${squid_cachedir} ]; then + echo "Creating ${squid_cachedir} ..." install -d -o ${squid_user} -g ${squid_group} \ - -m 0750 ${squid_base}/${dir} + -m 0750 ${squid_cachedir} fi - done if [ ! -d ${squid_confdir} ]; then echo "Creating ${squid_confdir}..." install -d -o root -g ${squid_group} \ -m 0755 ${squid_confdir} fi + if [ ! -d ${squid_logdir} ]; then + echo "Creating ${squid_logdir}..." + install -d -o ${squid_user} -g ${squid_group} \ + -m 0750 ${squid_logdir} + fi + if [ ! -d ${squid_rundir} ]; then + echo "Creating ${squid_rundir}..." + install -d -o ${squid_user} -g ${squid_group} \ + -m 0755 ${squid_rundir} + fi ;; POST-INSTALL) for file in cachemgr.conf errorpage.css mime.conf msntauth.conf squid.conf; do diff --git a/www/squid31/files/pkg-message.in b/www/squid31/files/pkg-message.in index 5979dcacbbc0..82f59cb52d77 100644 --- a/www/squid31/files/pkg-message.in +++ b/www/squid31/files/pkg-message.in @@ -1,8 +1,8 @@ o You can find the configuration files for this package in the directory %%PREFIX%%/etc/squid. - o A cache directory has been created in %%PREFIX%%/squid/cache. - Log files will be written to %%PREFIX%%/squid/logs. + o The default cache directory is /var/squid/. + The default log directory is /var/log/squid/. Note: You must initialize new cache directories before you can start @@ -10,13 +10,11 @@ If your cache directories are already initialized (e.g. after an upgrade of squid) you do not need to initialize them again. - o The default configuration will deny everyone access to the - proxy service. Edit the "http_access" directives in - %%PREFIX%%/etc/squid/squid.conf to suit your needs. - - Please note that the Squid start script is an rc.d style script. - This means that Squid will not start automatically at boot - time unless it is explicitly enabled. + o The default configuration will deny everyone but the local host and + local networks as defined in RFC 1918 for IPv4 and RFCs 4193 and + 4291 for IPv6 access to the proxy service. Edit the "http_access + allow/deny" directives in %%PREFIX%%/etc/squid/squid.conf + to suit your needs. To enable Squid, set squid_enable=yes in either /etc/rc.conf, /etc/rc.conf.local or /etc/rc.conf.d/squid diff --git a/www/squid31/files/squid.in b/www/squid31/files/squid.in index 41cfab956d75..7ab0c9e01aae 100644 --- a/www/squid31/files/squid.in +++ b/www/squid31/files/squid.in @@ -13,7 +13,7 @@ # Additional variables you can define in one of these files: # # squid_chdir: the directory into which the rc system moves into before -# starting Squid. Default: %%PREFIX%%/squid +# starting Squid. Default: /var/squid # # squid_conf: The configuration file that Squid should use. # Default: %%PREFIX%%/etc/squid/squid.conf @@ -32,7 +32,7 @@ # squid_pidfile: # The name (including the full path) of the Squid # master process' PID file. -# Default: %%PREFIX%%/squid/squid.pid. +# Default: /var/run/squid/squid.pid. # You only need to change this if you changed the # corresponding entry in your Squid configuration. # @@ -73,11 +73,11 @@ stop_cmd="squid_stop" load_rc_config ${name} -squid_chdir=${squid_chdir:-"%%PREFIX%%/squid"} +squid_chdir=${squid_chdir:-"/var/squid"} squid_conf=${squid_conf:-"%%PREFIX%%/etc/squid/squid.conf"} squid_enable=${squid_enable:-"NO"} squid_fib=${squid_fib:-"NONE"} -squid_pidfile=${squid_pidfile:-"%%PREFIX%%/squid/squid.pid"} +squid_pidfile=${squid_pidfile:-"/var/run/squid/squid.pid"} squid_user=${squid_user:-%%SQUID_UID%%} pidfile=${squid_pidfile} diff --git a/www/squid31/pkg-descr b/www/squid31/pkg-descr index afad41314353..0cd02912d960 100644 --- a/www/squid31/pkg-descr +++ b/www/squid31/pkg-descr @@ -7,7 +7,4 @@ Squid supports SSL, extensive access controls, and full request logging. By using the lightweight Internet Cache Protocol, Squid caches can be arranged in a hierarchy or mesh for additional bandwidth savings. -NOTE: This is a beta version. Stable Squid versions are located in - www/squid (2.7 series) and www/squid30 (3.0 series). - WWW: http://www.squid-cache.org/ |