Welcome! Log In Create A New Profile

Advanced

rooted/aliased locations and ngx_http_map_uri_to_path()

May 28, 2012 08:32AM
Привет,

существует конфиг:

[...]
root /opt/www/mysite;

location /jquery/ {
try_files $uri $uri/ @common;
}

location /resources/ {
try_files $uri $uri/ @common;
}

location @common {
root /opt/www/_common;
}
[...]

каким образом можно получить путь к файлу, находящимся в /opt/www/_common из собственного 3rd party модуля? ngx_http_map_uri_to_path() не понимает locations, сконфигурированных через alias/root. ngx_http_map_uri_to_path(r, &path, &root, 0) не работает. Существуют ли альтернативные методы получения пути к файлу из URI, соответствующего локейшну с собственным root?

Благодарю за помощь,

Андрей
Subject Author Posted

rooted/aliased locations and ngx_http_map_uri_to_path()

locojohn May 28, 2012 08:32AM

Re: rooted/aliased locations and ngx_http_map_uri_to_path()

locojohn June 01, 2012 07:13AM

Re: rooted/aliased locations and ngx_http_map_uri_to_path()

Maxim Dounin June 03, 2012 04:52AM

Re: rooted/aliased locations and ngx_http_map_uri_to_path()

locojohn June 03, 2012 12:01PM

Re: rooted/aliased locations and ngx_http_map_uri_to_path()

Валентин Бартенев June 03, 2012 12:38PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 174
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