I am using nginx to serve my django static files. In the browser I can see that they are loaded, base.css, login.css, responsive.css all got status 200, I can click on them and see their content.
The problem is that they don't seem to be applied in the html. The html still looks like it has no css formatting applied to it at all. There are no errors in the nginx logs and no errors in the network tab in chrome. I have tried chrome and firefox
Using Django 2.2.4
Relevant nginx config
server {
listen 8000;
server_name 127.0.0.1;
location /static/ {
autoindex on;
alias /home/ubuntu/<SECRET_PATH>/static/;
}
location / {
include proxy_params;
proxy_pass http://unix:/home/ubuntu/<SECRET_PATH>/dashboard.sock;
}
}
collectstaticand still it doesn't work (like you said that CSS files load), does the server return proper mime types for CSS files?