Hello everyone!
I tried deploying flarum under Nginx and it returned a 403 error.
Here is my config file:
#user nginx;
worker_processes auto;
error_log /var/log/nginx/error.log;
pid /run/nginx.pid;
include /usr/share/nginx/modules/*.conf;
events {
worker_connections 10240;
}
http {
#access_log /var/log/nginx/access.log main;
sendfile on;
tcp_nopush on;
tcp_nodelay on;
keepalive_timeout 65;
types_hash_max_size 2048;
include /etc/nginx/mime.types;
default_type application/octet-stream;
include /etc/nginx/conf.d/*.conf;
server {
listen 80;
server_name <MYDOMAIN>;
root /var/www/bbs;
index index.php index.html index.htm;
try_files $uri $uri/ /index.html;
include /var/www/bbs/.nginx.conf;
location ~ \.php$ {
fastcgi_pass unix:/var/run/php/php8.1-fpm.sock;
fastcgi_index index.php;
include fastcgi_params;
}
}
}
Can you help me? Thanks!