[squid-users] port redirection using accelerator mode

From: ghatos <ghatos@dont-contact.us>
Date: Wed, 17 Oct 2007 09:54:08 -0700 (PDT)

I'm wondering if this is possible.

I would like a single squid to proxy traffic arriving on port 80 to
different server and different ports inside my network based on URL. Detail
follows:

I have a squid that is configured in accelerator mode to proxy all requests
coming in on port 80 to several origin servers inside my network. This
works great. All requests come in on port 80 and are redirected to port
80.

I also have two tomcat servers inside the network. These servers are
running tomcat and apache. Apache is configured with a virtual host that
redirects the query to another URL (local to the server) after adding port
:8080 to the URL for tomcat. I have not been able to get these working via
squid.

I was wonding how I could configure squid to forward specific URLs to these
tomcat origin server with port :8080 appended to the URL?

squid.conf currently looks like this:
hosts_file /etc/squid/hosts
http_port 80

httpd_accel_host virtual
httpd_accel_single_host off
httpd_accel_uses_host_header on

acl all src 0.0.0.0/0
acl alldst dst 0.0.0.0/0

acl origin dst [ a bunch of internal IP addresses ]
cache_effective_user squid
cache_effective_group squid

acl Safe_ports port 80 # http
acl Safe_ports port 443 # https

http_access deny !Safe_ports

acl cache_prevent1 url_regex cgi-bin /?
acl cache_prevent2 url_regex Servlet
no_cache deny cache_prevent1
no_cache deny cache_prevent2

http_access allow origin
http_access deny alldst
http_access deny all

#redirect_program /usr/local/squirm/bin/squirm
#redirect_children 20

coredump_dir /var/spool/squid

ie_refresh on

Any help is appreciated.

-- 
View this message in context: http://www.nabble.com/port-redirection-using-accelerator-mode-tf4641887.html#a13258132
Sent from the Squid - Users mailing list archive at Nabble.com.
Received on Wed Oct 17 2007 - 10:54:10 MDT

This archive was generated by hypermail pre-2.1.9 : Thu Nov 01 2007 - 13:00:01 MDT