Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'd like to setup a squid instance to do selective reverse proxy for a configured list of URLs whilst acting as a normal forward proxy for everything else.

We are building new infrastructure, parallel live as it where, and I want to have a proxy that people can use that will force selective traffic into the new platform whilst just acting as a forward proxy for anything else. This makes it very easy for people/systems to test the portions of the new platform we want without having to change too much, just use a proxy address.

Is such a setup possible ?

share|improve this question

The following seems to work for me, anything for gets sent to the new servers and everything else is proxied as normal.

# Setup a cache peer as an origin server 
# Duplicate this line for each site you want to reverse for and give it a new name
cache_peer <new platform ip or fqdn> parent 80 0 no-query originserver proxy-only name=upstream1

# Set the domain the cache_peer should handle
cache_peer_domain upstream1

# Duplicate following three lines
# Add as many acl lines as necessary for all domains handled
acl our_sites  dstdomain
cache_peer_access upstream1_sites allow our_sites
cache_peer_access upstream1_sites deny all 
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.