Nginx: Avoid redirect loops.
Merge branch 'refs/heads/6.x-2.x' into 2.3.x-dev