server { server_name sonerezh.localhost; access_log /var/log/nginx/sonerezh.access.log; error_log /var/log/nginx/sonerezsh.error.log; root /usr/share/webapps/sonerezh/app/webroot; index index.php; location / { try_files $uri $uri/ /index.php?$args; expires 14d; add_header Cache-Control 'public'; } location ~ \.php$ { fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_index index.php; fastcgi_pass unix:/run/php-fpm/php-fpm.sock; include fastcgi_params; } }