Open sitilge opened 8 years ago
Heres my nginx config, it works well. Hope this help.
Nginx/1.6.3
server {
server_name 127.0.0.1;
root PATH_TO_WEBROOT;
index index.php;
#site root is redirected to the app boot script
location = / {
try_files @site @site;
}
#all other locations try other files first and go to our front controller if none of them exists
location / {
try_files $uri $uri/ @site;
}
#return 404 for all php files as we do have a front controller
location ~ \.php$ {
return 404;
}
location @site {
fastcgi_pass 127.0.0.1:9000;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root/index.php;
}
location ~ .*/\. {
deny all;
}
}
and don't forget set the corresponding value in src/app.php $app['asset_path'] = '/resources';
Hi there,
Moved to nginx recently. Using this config but still when moving to
example.com/someTable
the 404 is thrown by nginx. Any ideas?