Here's my static website directory tree:
- website
-- html
--- index.html
-- css
--- styles.css
-- js
Here's my nginx config:
server {
listen 80;
root /srv/www/domain.com/website/html;
index index.php index.html index.htm;
server_name domain.com;
location / {
try_files $uri $uri/ =404;
}
location ~ \.php$ {
include snippets/fastcgi-php.conf;
fastcgi_pass unix:/run/php/php7.0-fpm.sock;
}
location ~ /\.ht {
deny all;
}
}
However it cannot load css / js files, it says 404 not found. What's wrong?
solved my issues.