Welcome! Log In Create A New Profile

Advanced

Re: Reverse proxy, subdomain

February 27, 2012 12:54PM
On Mon, 2012-02-27 at 12:19 +0100, vicosoft@gmail.com wrote:
> ok, I've solved using the IF statement.
if ($http_host = m.mua.es) {

No, this is a bad way to solve it. Please see
http://wiki.nginx.org/IfIsEvil

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

server {
server_name m.mua.es;
...
}

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

Regards,
Cliff


_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Reverse proxy, subdomain

vicosoft@gmail.com February 27, 2012 05:20AM

Re: Reverse proxy, subdomain

vicosoft@gmail.com February 27, 2012 05:46AM

Re: Reverse proxy, subdomain

vicosoft@gmail.com February 27, 2012 06:20AM

Re: Reverse proxy, subdomain

Cliff Wells February 27, 2012 12:54PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 171
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready