should I run nginx for static content on port 81 or set it up as reverse proxy to apache?

Which is a better idea and why? I'm currently simply running nginx on port 81. i was wondering if there are any benefits as running it on port 80 instead and proxy to apache that sits on 8080 for example?

link|improve this question

47% accept rate
feedback

2 Answers

up vote 2 down vote accepted

If you have clients in the corporate world than having a site that servers content on non-standard ports may cause issues. A lot of companies will only allow certain ports (80,443, sometimes 8080) out. This obviously isn't a universal standard but having someone email you saying your page loads but has no images or css can be a bit frustrating.

link|improve this answer
feedback

I find it a hassle to use a non standard port to handle HTTP. The devs have to make sure to always add the port option and secondly tomorrow if you decide to use a CDN you wouldn't be able to.

The other option could be that you configure another subdomain like static.yourdomain.com and don't proxy it.

link|improve this answer
What Pratik Amin said is also true. – Sameer May 28 '11 at 1:50
feedback

Your Answer

 
or
required, but never shown

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