<div dir="ltr">Hi,<div><br></div><div>Below is default foswiki config that falls into "rewrite or internal redirection cycle while processing "/bin/view/bin/view/bin/view/bin/view/bin/view/bin/view/bin/view/bin/view/bin/view/bin/view/Main/WebHome"".</div><div><br></div><div>This is Nginx 1.11.6.</div><div><br></div><div>Any ideas?</div><div><br></div><div><div> location = / { </div><div> root $foswiki_root;</div><div> rewrite .* /Main/WebHome;</div><div> }</div><div> location ~ ^/([A-Z_].*)$ {<br></div><div> rewrite ^/(.*)$ /bin/view/$1;</div><div> }</div><div> location ~ ^/bin/([a-z]+) {<br></div><div> fastcgi_param SCRIPT_NAME $1; </div><div> gzip off;</div><div> #fastcgi_pass unix:/var/run/nginx/foswiki.sock;</div><div> fastcgi_pass <a href="http://127.0.0.1:9000">127.0.0.1:9000</a>;</div><div> fastcgi_split_path_info ^(/bin/\w+)(.*);</div><div> fastcgi_param SCRIPT_FILENAME $foswiki_root/$fastcgi_script_name;</div><div> fastcgi_param SCRIPT_NAME $fastcgi_script_name;</div><div> fastcgi_param PATH_INFO $fastcgi_path_info;</div><div> include fastcgi_params;</div><div> }</div><div><br></div><div>Debug log:</div><div><br></div><div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 test location: "/"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 using configuration "=/"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 http cl:-1 max:104857600</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 rewrite phase: 2</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 http script regex: ".*"</div><div>2016/12/15 14:24:02 [notice] 15695#0: *6 ".*" matches "/", client: 127.0.0.1, server: <a href="http://wiki.sports.ru">wiki.sports.ru</a>, request: "GET / HTTP/1.1", host: "<a href="http://wiki.sports.ru">wiki.sports.ru</a>"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 http script copy: "/Main/WebHome"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 http script regex end</div><div>2016/12/15 14:24:02 [notice] 15695#0: *6 rewritten data: "/Main/WebHome", args: "", client: 127.0.0.1, server: <a href="http://wiki.sports.ru">wiki.sports.ru</a>, request: "GET / HTTP/1.1", hos</div><div>t: "<a href="http://wiki.sports.ru">wiki.sports.ru</a>"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 post rewrite phase: 3</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 uri changes: 11</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 test location: "/"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 test location: ~ "^/([A-Z_].*)$"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 using configuration "^/([A-Z_].*)$"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 http cl:-1 max:104857600</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 rewrite phase: 2</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 http script regex: "^/(.*)$"</div><div>2016/12/15 14:24:02 [notice] 15695#0: *6 "^/(.*)$" matches "/Main/WebHome", client: 127.0.0.1, server: <a href="http://wiki.sports.ru">wiki.sports.ru</a>, request: "GET / HTTP/1.1", host: "wiki</div><div>.<a href="http://sports.ru">sports.ru</a>"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 http script copy: "/bin/view/"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 http script capture: "Main/WebHome"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 http script regex end</div><div>2016/12/15 14:24:02 [notice] 15695#0: *6 rewritten data: "/bin/view/Main/WebHome", args: "", client: 127.0.0.1, server: <a href="http://wiki.sports.ru">wiki.sports.ru</a>, request: "GET / HTTP/1.1", host: "<a href="http://wiki.sports.ru">wiki.sports.ru</a>"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 post rewrite phase: 3</div></div><div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 uri changes: 10</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 test location: "/"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 test location: ~ "^/([A-Z_].*)$"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 using configuration "^/([A-Z_].*)$"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 http cl:-1 max:104857600</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 rewrite phase: 2</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 http script regex: "^/(.*)$"</div><div>2016/12/15 14:24:02 [notice] 15695#0: *6 "^/(.*)$" matches "/bin/view/Main/WebHome", client: 127.0.0.1, server: <a href="http://wiki.sports.ru">wiki.sports.ru</a>, request: "GET / HTTP/1.1", host: "<a href="http://wiki.sports.ru">wiki.sports.ru</a>"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 http script copy: "/bin/view/"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 http script capture: "bin/view/Main/WebHome"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 http script regex end</div><div>2016/12/15 14:24:02 [notice] 15695#0: *6 rewritten data: "/bin/view/bin/view/Main/WebHome", args: "", client: 127.0.0.1, server: <a href="http://wiki.sports.ru">wiki.sports.ru</a>, request: "GET / HTTP/1.1", host: "<a href="http://wiki.sports.ru">wiki.sports.ru</a>"</div><div>2016/12/15 14:24:02 [debug] 15695#0: *6 post rewrite phase: 3</div></div><div><br></div><div><br></div>-- <br><div class="gmail_signature"><div dir="ltr"><div>Руслан Закиров</div><div>Руководитель отдела разработки веб-сервисов</div><div><span>+7(916) 597-92-69</span>, <span>ruz @ <a href="http://www.sports.ru/" target="_blank"><img src="http://farm7.static.flickr.com/6235/6210250811_19a888dbba_o.jpg" width="43" height="14" style="vertical-align: bottom; margin-right: 0px;"></a></span></div></div></div>
</div></div>