> How do I configure nginx and uwsgi when the url is suppose:
>
> /a/b/c/
>
> and it needs to map to a file of:
>
> /home/app1/public_html/index.php
>
> I guess the SCRIPT_NAME that PHP will see must stay the same /a/b/c/ url
> path, so that the PHP app can generate proper urls in the HTML output.
>
>

Php (and generally, CGIs) works a bit different from WSGI/PSGI/Rack.

On Apache you use mod_rewrite to accomplish that, in nginx there is the
rewrite system, but i personally prefer to have uWSGI manage such
rewrites:

route = ^/a/b/c/ rewrite:/index.php

or (i suppose you want something that)

route = ^/a/b/c/(.*) rewrite:/index.php$1

be sure to have compiles uWSGI with routing support (requires pcre)

Note:

the rewrite router is undocumented, but follows the rules of the other
routing plugins:

http://projects.unbit.it/uwsgi/wiki/InternalRouting

-- 
Roberto De Ioris
http://unbit.it
_______________________________________________
uWSGI mailing list
[email protected]
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi

Reply via email to