3

I need to setup a proxy server where we can request remote urls and get them served locally.

Basically what I need is

mysever:8000/varnish/serverfault.com get me serverfault.com served from my local varnish

or

myserver:8080/squid/serverfault.com get me serverfault.com served from my local squid.

(Both should cache the site for 24 hours)

I am evaluating if

  1. Varnish or Squid will be a good choice for it.
  2. Which one will be a better fit?
  3. How do I do it. Links to tutorials would be good.
shabda
  • 300
  • 1
  • 4
  • 10

1 Answers1

1

It would be fairly straightforward to do with squid - using a urlrewriter which checks the mtime on the local copy (if available) and downloads a new copy to the server filesystem is its required.

See http://www.ex-parrot.com/pete/upside-down-ternet.html for an example of how to do something similar.

symcbean
  • 21,009
  • 1
  • 31
  • 52