Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

ive installed redmine on a subdomain per the instruction here > http://library.linode.com/web-applications/project-management/redmine/ubuntu-10.04-lucid Its actually not working yet but another story.

my main concern is anytime i go to anything.domain.com i get directed to the same thing, (redmine/nginx).

what throws me off is if i have a subdomain running/created with virtualmin, that works ok. it just seems like port 8080 is a catchall, where i prefer that the catchall is apache at port 80 so it can say "you dont have permission".

here is my virtualhost (ive also used localhost:8080 instead of the domain name, doesn’t seem to make a difference.

 ServerAdmin me@me.com
 ServerName proj.domain.com

 ProxyPass / http://proj.domain.com:8080/
 ProxyPassReverse / http://proj.domain.com:8080/

 # Uncomment the line below if your site uses SSL.
 SSLProxyEngine On

or maybe im looking in the wrong place to do this?? thanks!

share|improve this question
Well you reversed the normal order of things, usually nginx proxies to Apache because it does not block on network interaction and handles low connection speed clients much better. Consider moving Apache behind nginx. –  Alex Aug 10 '12 at 15:46

2 Answers 2

not sure which is better, both seem to work, although according to another answer here, this is the correct way

        ServerName  sub.domain.net (one i want nginx on)
        ProxyRequests Off
        <Proxy *>
                Order deny,allow
                allow from all
        ProxyPreserveHost On
        ProxyPass / http://domain.net:8080 (all other, i want apache on everything except sub)
        ProxyPassReverse / http://domain.net:8080
        ProxyErrorOverride Off
        ErrorDocument 404 /notavail.html
share|improve this answer

correct, thanks alex.

ive changed the proxy pass to port 80

so now i have this in /etc/apache2/sites-available/sub.domain.net and everything except the specified domain go to port 80

 ServerAdmin me@me.com
 ServerName sub.domain.net

 ProxyPass / http://localhost:80/
 ProxyPassReverse / http://localhost:80/

 # Uncomment the line below if your site uses SSL.
 # SSLProxyEngine On
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.