brainfoolong / omxwebgui-v2

Web GUI for OMX Player on a Raspberry Pi
https://www.youtube.com/watch?v=4hqOzdt6KfQ
MIT License
53 stars 17 forks source link

URL mapping fails when used with nginx #3

Closed robmint closed 7 years ago

robmint commented 7 years ago

I'm running omxwebgui-v2 with nginx because I have another web interface that i'd like to co-exist with omxwebgui.

When I go to a URL like http://127.0.0.1/player/index.php/settings I get 404. Is there a rewrite rule I can add to make that work?

robmint commented 7 years ago

I found this config worked:

    location ~ [^/]\.php(/|$) {
        include snippets/fastcgi-php.conf;
        fastcgi_split_path_info ^(.+?\.php)(/.*)$;
        if (!-f $document_root$fastcgi_script_name) {
        return 404;
        }
        fastcgi_pass unix:/var/run/php5-fpm.sock;
    }
brainfoolong commented 7 years ago

Ok, thx for letting me know.