"IP" /static/defaul.css и "IP" / stati c показывают 403 запрещенных nginx / 1.16.1 (Ubuntu), и когда я запускаю веб-сайт, страницы отображаются без css
Я работаю с Linode, UFW, Ubuntu
Последние команды были:
`sudo apt install nginx`
`pip install gunicorn`
`sudo rm /etc/nginx/sites-enabled/default`
`sudo nano /etc/nginx/sites-enabled/Preistracker`
fill in: server {
listen 80;
server_name "IP";
location /static {
alias /home/lukas/Preistracker/main/static;
}
location / {
proxy_pass http://localhost:8000;
include /etc/nginx/proxy_params;
proxy_redirect off;
}
}
`sudo nano ufw allow http/tcp`
`sudo ufw delete allow 5000`
`sudo ufw enable`
`sudo systemctl restart nginx`
Sudo UFW статус:
To Action From
-- ------ ----
22/tcp ALLOW Anywhere
80/tcp ALLOW Anywhere
8000 ALLOW Anywhere
22/tcp (v6) ALLOW Anywhere (v6)
80/tcp (v6) ALLOW Anywhere (v6)
8000 (v6) ALLOW Anywhere (v6)