Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

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 need to redirect all the requests from localhost:8080/app1/ to localhost/app1.

which is the best way to do it.

The only requirement is that the user must never be aware that he is accessing the application at port 80. i guess I need to set up Apache HTTPD proxying - I'm just not sure which is the best way to do it.

Thanks in advance.

share|improve this question

migrated from Apr 7 '10 at 3:20

This question came from our site for professional and enthusiast programmers.

up vote 1 down vote accepted

Here's a full example, it's what I use to frontend apt-proxy with an apache that's already using port 80.

You need to put this either inside the relevent VirtualHost directive.

    ProxyRequests on
    ProxyPass               /
    ProxyPassReverse        /

            Order allow,deny
            Deny from none
            Allow from all

You may also need to run a2enmod proxy if the proxy module isn't enabled by default.

share|improve this answer

You're looking for "reverse proxy" configuration. Check the mod_proxy docs, look at ProxyPass.

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.