Skip to content
This repository has been archived by the owner on May 22, 2023. It is now read-only.

Add an nginx config gotcha to quick install wiki page #25

Open
gfdsa opened this issue Dec 1, 2013 · 0 comments
Open

Add an nginx config gotcha to quick install wiki page #25

gfdsa opened this issue Dec 1, 2013 · 0 comments

Comments

@gfdsa
Copy link

gfdsa commented Dec 1, 2013

The thing that requires a special treatment is the usage of Apache's REDIRECT_URL instead of request uri. Given a working nginx config with fastcgi to php, one has to add a mapping of the original path before rewrite to php. My relevant working config looks like this:

    location / {
            root    /var/www/tonicdns/TonicDNS/docroot;
            try_files $uri $uri/ /dispatch.php;
    }
    location ~ \.php {
            root    /var/www/tonicdns/TonicDNS/docroot;
            fastcgi_pass   127.0.0.1:9001;
            include fastcgi_params;
            fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;
            fastcgi_param  REDIRECT_URL $request_uri;
    }
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant