Add nginx rewrite support

Issue #4 resolved
Former user created an issue

I can see that egs only supporting apache rewrite, is there any changes to support nginx also?, i have many problems running it on nginx.

Comments (2)

  1. Brenton Scott

    There is no official nginx example for this, but I have written one myself:

        server {
            listen      64.85.165.64:80;
            server_name  egs.gigirc.com egs.gigmirc.com;
            root         html;
            index  index.php index.html;
            
            location / {
                    try_files $uri $uri/ @rewrite;
            }
     
            location @rewrite {
                    rewrite ^/(.*)$ /index.php?/$1&$args;
            }
    
            location ~ \.php$ {
               include        fastcgi_params;
               fastcgi_pass   localhost:53217;
               fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;
            }
        }
    

    Use at your own risk ;)

  2. Log in to comment