Q: about try_files and regex location

Valentin V. Bartenev ne at vbart.ru
Fri Nov 11 13:15:02 UTC 2011


On Friday 11 November 2011 16:16:25 Aleksandar Lazic wrote:
[...]
> ###
> http {
>    server {
> ...
>          location ~ ^/(share|alfresco)(/res)?(.*$)  {
 - location ~ ^/(share|alfresco)(/res)?(.*$)  {
 + location ~ ^/(share|alfresco)(/res)?(.*)$  {

>            alias /home/alfresco/alfresco-4.0.b/tomcat/webapps;
[...]

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

The "alias" directive in your config replaces request part of path to file after 
successful "try_files" check.

wbr, Valentin V. Bartenev

 



More information about the nginx mailing list