2

I'm trying to implement django-filebrowser into my latest app. I have grappelli installed also. The urls work fine for getting into filebrowser /admin/filebrowser/browse is what I have it set at.

The problem I am having is when it comes to trying to either add a folder or upload a file.

New Folder:

When I'm adding a folder an error is thrown stating:

Please correct the following errors.

Permission denied.

Now the permissions for the folder are fine. I don't understand why it won't allow me to upload files here.

drwxr-xr-x 2 naytive naytive 4096 Jan 18 08:32 uploads/

Upload File:

Normally when uploading a file, the filebrowser upload screen appears with a timer to upload success, however when I try to upload a file it just refreshes the page with url ending

?_save=Upload

It is getting to the point where I will just remove the module because it isn't doing as it is set up to be.

Any ideas?

EDIT: I think the uploading files side of things is caused by the original file permissions also. If we fix this error then perhaps the upload will work too.

Community
  • 1
  • 1
Llanilek
  • 3,386
  • 5
  • 39
  • 65
  • "Now the permissions for the folder are fine." What about the parent folders? Each parent must have "X" permission. – S.Lott Jan 26 '11 at 02:07
  • How far back do the permissions need to go? as the parent is also set to 755 – Llanilek Jan 26 '11 at 02:14
  • Permissions set to 755 is not enough if Django process runs under another user than naytive or not part of naytive group. Are you testing it with the dev server ? – Eric Fortin Feb 04 '11 at 18:22
  • I'm not testing it with the dev server no its running on mod_wsgi, how would i check what user is trying to run it. As far as I am aware it should be naytive. – Llanilek Feb 04 '11 at 22:12
  • is FILE_UPLOAD_PERMISSIONS set in your settings? After updating filebrowser I had a similar problem, it seemed to be whenever a new folder was created? adding the settings seemed to work for me. – JamesO Feb 08 '11 at 13:00

2 Answers2

1

If you use it on a server with apache, then you must give apache right to write in this folder (chown).

sth
  • 222,467
  • 53
  • 283
  • 367
Azd325
  • 5,752
  • 5
  • 34
  • 57
1

I had something similar. I gave permission to www-data user to the folder i wanted to upload to and it worked.

darren
  • 18,845
  • 17
  • 60
  • 79
  • so your referring to chown www-data ? – Llanilek Feb 10 '11 at 18:36
  • I guess so. I have a gui interface so I don't know the actual command. I had to chown 777 the dir and give the www-data user and group permission to write. – darren Feb 11 '11 at 08:04