34 lines
853 B
Text
34 lines
853 B
Text
|
|
||
|
# Default server configuration
|
||
|
#
|
||
|
server {
|
||
|
listen 80 default_server;
|
||
|
listen [::]:80 default_server;
|
||
|
|
||
|
root /var/www/html/symfony_blog/current/public;
|
||
|
|
||
|
index index.php;
|
||
|
|
||
|
server_name _;
|
||
|
|
||
|
location / {
|
||
|
try_files $uri /index.php$is_args$args;
|
||
|
}
|
||
|
|
||
|
location ~ ^/index\.php(/|$) {
|
||
|
fastcgi_pass unix:/var/run/php/php7.4-fpm.sock;
|
||
|
fastcgi_split_path_info ^(.+\.php)(/.*)$;
|
||
|
include fastcgi_params;
|
||
|
fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name;
|
||
|
fastcgi_param DOCUMENT_ROOT $realpath_root;
|
||
|
internal;
|
||
|
}
|
||
|
|
||
|
location ~ \.php$ {
|
||
|
return 404;
|
||
|
}
|
||
|
|
||
|
error_log /var/log/nginx/symfony_blog_error.log;
|
||
|
access_log /var/log/nginx/symfony_blog_access.log;
|
||
|
}
|