Reverse proxy, subdomain

Cliff Wells cliff at
Mon Feb 27 17:52:10 UTC 2012

On Mon, 2012-02-27 at 12:19 +0100, vicosoft at wrote:
> ok, I've solved using the IF statement.
if ($http_host = {

No, this is a bad way to solve it. Please see

Instead, set up a separate server block for that subdomain:

server {

If you want to avoid repeating large blocks of configuration across
multiple server blocks, use the include directive.


More information about the nginx mailing list