Alan Tingey
Alan Tingey

Reputation: 961

Django permissions hiccup

I had all my static and media files working perfectly. However, when I wanted to create a new news article and therefore upload a new picture I got the following error:

[Errno 13] Permission denied: 

At the following link I found:

Django [Errno 13] Permission denied: '/var/www/media/animals/user_uploads'

sudo groupadd varwwwusers
sudo adduser www-data varwwwusers
sudo chgrp -R varwwwusers /var/www/
sudo chmod -R 770 /var/www/

Now none of my static files will display on the site at str8red.com

Can anyone help with getting the file permissions back and also allowing the webpage to allow upload of new images.

Many thanks, Alan.

Upvotes: 0

Views: 85

Answers (1)

Alan Tingey
Alan Tingey

Reputation: 961

Apologies,

After further digging and grasping the basics of chmod I got there. The links below were very helpful:

www-data permissions?

https://en.wikipedia.org/wiki/Chmod

Many thanks, Alan.

Upvotes: 1

Related Questions