Ткните пальцем. Что я делаю не так? В тему начал только вникать. Корень работает, не работают /01 и /02.
server {
listen 80;
listen [::]:80;
# listen 443 ssl;
# listen [::]:443 ssl;
server_name test-01;
access_log /var/log/nginx/test-01.access.log.machine-01;
error_log /var/log/nginx/test-01.error.log.machine-01;
root /var/www/test-01;
# index index.html;
# index index.html index.htm index.nginx-debian.html;
index index.php;
location / {
# First attempt to serve request as file, then
# as directory, then fall back to displaying a 404.
try_files $uri $uri/ =404;
# root /var/www/test-01;
# index index.php;
}
location /01 {
alias /var/www/test-01;
# index index.php;
}
location /02 {
alias /var/www/test-02;
# index index.php;
}
location ~ \.php$ {
include snippets/fastcgi-php.conf;
# fastcgi_pass 127.0.0.1:9000;
fastcgi_pass unix:/run/php/php7.4-fpm.sock;
}
location ~ /\.ht {
deny all;
}
}