Welcome! Log In Create A New Profile

Advanced

Re: nginx+xbt tracker

Sergey Shepelev
December 08, 2010 03:04PM
2010/12/8 agz <nginx-forum@nginx.us>:
> Тут проблема возникла правильно
> прописать location...
> Дело в том что nginx не распознает /announce в
> конце строки и выдает 404.
> URL: http://host:2710/$passkey/announce
> Если passkey не использовать - все
> работает.
> location ~ ^/(an|announce) - так не находит location и
> получаем 404.
>

Символ ^ в регекспах означает начало строки.

^/an заматчит любую строку, которая начинается с /an. Строка
/$passkey/announce, очевидно, сюда не подходит.
/an$ заматчит любую строку, которая заканчивается на /an. Возможно,
вам нужно именно это.

Более точно можно описать так:

location ~ ^/[^/]+/(an|announce)$
Сюда попадут урлы

/fababa/an
/dadada/announce

но не попадут

/fa/ba/an
/ba/ja/announce
/announce
_______________________________________________
nginx-ru mailing list
nginx-ru@nginx.org
http://nginx.org/mailman/listinfo/nginx-ru
Subject Author Posted

nginx+xbt tracker

agz December 03, 2010 09:06AM

Re: nginx+xbt tracker

Roman Sokolov December 03, 2010 11:04AM

Re: nginx+xbt tracker

Oleg Motienko December 03, 2010 02:46PM

Re: nginx+xbt tracker

agz December 03, 2010 05:16PM

Re: nginx+xbt tracker

xpahos@gmail.com December 03, 2010 05:34PM

Re: nginx+xbt tracker

agz December 05, 2010 01:29PM

Re: nginx+xbt tracker

agz December 08, 2010 02:40PM

Re: nginx+xbt tracker

Sergey Shepelev December 08, 2010 03:04PM

Re: nginx+xbt tracker

agz December 08, 2010 03:08PM

Re: nginx+xbt tracker

agz December 08, 2010 03:54PM

Re: nginx+xbt tracker

agz December 08, 2010 04:47PM

Re: nginx+xbt tracker

Sergey Shepelev December 08, 2010 03:24PM

Re: nginx+xbt tracker

Vladimir Sopot December 08, 2010 03:38PM

Re: nginx+xbt tracker

Igor Sysoev December 08, 2010 04:08PM

Re: nginx+xbt tracker

Igor Sysoev December 08, 2010 04:10PM

Re: nginx+xbt tracker

Gmail December 10, 2010 03:34AM

Re: nginx+xbt tracker

agz December 11, 2010 04:52AM

Re: nginx+xbt tracker

Igor Sysoev December 11, 2010 05:10AM

Re: nginx+xbt tracker

Igor Sysoev December 11, 2010 05:14AM

Re: nginx+xbt tracker

agz December 11, 2010 05:56AM

Re: nginx+xbt tracker

agz December 11, 2010 06:05AM

Re: nginx+xbt tracker

agz December 11, 2010 06:25AM

Re: nginx+xbt tracker

Igor Sysoev December 11, 2010 06:00AM

Re: nginx+xbt tracker

Igor Sysoev December 11, 2010 06:16AM

Re: nginx+xbt tracker

agz December 12, 2010 10:18AM

Re: nginx+xbt tracker

agz December 13, 2010 02:23PM

Re: nginx+xbt tracker

Igor Sysoev December 13, 2010 02:30PM

Re: nginx+xbt tracker

agz December 13, 2010 02:41PM

Re: nginx+xbt tracker

Igor Sysoev December 13, 2010 02:44PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 60
Record Number of Users: 6 on February 13, 2018
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready