Preferred method for location blocks

What is the difference between:

location /admin {
}

vs.

location ~ /admin(/.*) {
}

The first seems cleaner, and I assume runs faster - but do they process
differently?


Daniel

On 01.04.2015 23:55, Daniel Miller wrote:

The first seems cleaner, and I assume runs faster - but do they process
differently?

Yes, they process differently.

http://nginx.org/en/docs/http/ngx_http_core_module.html#location

http://nginx.org/en/docs/http/request_processing.html


Best regards,
Gena

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs