composer update
composer require cviebrock/eloquent-sluggable
server {
listen 80;
server_name blog.com;
root /var/www/blog/public;
add_header X-Frame-Options "SAMEORIGIN";
add_header X-XSS-Protection "1; mode=block";
add_header X-Content-Type-Options "nosniff";
# Add index.php to the list if you are using PHP
index index.php index.html index.htm index.nginx-debian.html;
charset utf-8;
#return 301 https://$server_name$request_uri;
location ~ \.php$ {
include snippets/fastcgi-php.conf;
fastcgi_pass unix:/run/php/php7.4-fpm.sock;
#fastcgi_index index.php;
#fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name;
#include fastcgi_params;
}
location / {
#try_files $uri $uri/ /index.php;
try_files $uri $uri/ /index.php?$query_string;
}
location = /favicon.ico { access_log off; log_not_found off; }
location = /robots.txt { access_log off; log_not_found off; }
# deny access to .htaccess files, if Apache's document root
#location ~ /\.ht {
#deny all;
#}
}