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

I'd like to configure a reverse http proxy to serve traffic from numerous internal webservers while exposing a single external ip.

I plan to have an externally published wildcard dns for *, and then a set of internal records for,, etc which could be frequently added/removed to dns.

Thus a user would do a look up for any of * and get the same ip, which directs to the reverse proxy. The reverse proxy is configured to use the internal dns to resolve, and the traffic is proxied to the particular internal node.

The requirement that has tripped me up is the ability to add/remove internal dns entries without having to touch the proxy configuration. I've experimented with squid and apache/mod_proxy but could not find a way to do this without specifying each host in the config, which becomes arduous / difficult to maintain.

I imagine this is a problem that has been solved before, though I'm not finding a lot on google. Any suggestions on what proxy tool I should use and any configuration tricks?

share|improve this question

1 Answer 1

up vote 0 down vote accepted

Try nginx , with something like this :

location / {
  proxy_pass http://$host/;
  proxy_set_header Host $host;

Though no idea if will work.
Docs at nginx wiki, proxy module .

share|improve this answer
Thanks - that worked. I added a server_name wildcard directive * and then a catch-all server block to deny all else. –  JackB May 8 '13 at 15:43

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.