configuring nginx to work with code igniter app
I have the following nginx configuration. I'm trying (vainly apparently) to configure it so that it works with code igniter. mydomain.com is my real website, mydomain.com/web is the app I'm trying to make work. Eventually I'll move the app to the root, but it's a workup of my current site using ci.
I can access mydomain.com/web, but mydomain.com/web/about errors because it can't open /var/www/web/page/about.
Thanks,
server {
root /var/www/tysdomain.com;
index index.html index.htm index.php;
location / {
}
location /web {
try_files index.php;
}
location ~* .(ico|png|css|js|jpg|jpgeg)$ {
expires max;
lognotfound off;
}
location ~ .php$ {
try_files $uri = 404;
include /etc/nginx/fastcgi_params;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgiparam SCRIPTFILENAME $documentroot$fastcgiscript_name;
}
}