I\'m using apache+mod_wsgi for django.
And all css/js/images are served through nginx
.
For some odd reason, when others/friends/colleagues try accessing
I also struggled with this. However, following trick worked for me:
server {
listen 8000;
server_name localhost;
access_log /var/log/nginx/aa8000.access.log;
error_log /var/log/nginx/aa8000.error.log;
location / {
index index.html index.htm;
}
location ^/static/ {
autoindex on;
root /opt/aa/webroot/;
}
}
I just marked static as a regex with ^
and nginx started serving static files. No modification on Django side was needed.