johntynan / django-newsroom

Automatically exported from code.google.com/p/django-newsroom
Other
0 stars 0 forks source link

Photologue OSError: [Errno 13] Permission denied #50

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
On the dev server, when I try to add a photologue photo I receive the
following error:

OSError: [Errno 13] Permission denied

I created the following alias

Alias /site_media/
/home/jetynan/sites/dev.news21.com/projects/django-newsroom/newsroom_project/med
ia/site_media/

I also changed the permissions on this directory to 777 (drwxrwxrwx).

However, I have the feeling that this has something to do with photologue
creating date based directories on the server.

Original issue reported on code.google.com by jgty...@gmail.com on 3 May 2009 at 3:42

Attachments:

GoogleCodeExporter commented 9 years ago
I believe this is fixed.  I created a site_media directory under 
newsroom_project and
then changed the persmissions.  I did not add a site_media alias to the apache
directives file (as I found this messed up the css for the reporter's admin 
interface).

Original comment by jgty...@gmail.com on 3 May 2009 at 4:10

GoogleCodeExporter commented 9 years ago
In apache create two aliases:

Alias /media/admin/ /path/to/django/contrib/admin/media
Alias /site_media/ /path/to/newsroom_project/media

That should do it.

Original comment by mand...@gmail.com on 3 May 2009 at 5:58

GoogleCodeExporter commented 9 years ago
Pretty sure you don't need ... newsroom_project/media/site_media/  (site_media 
is just a virtual path, you map it 
to the file system with an Alias directory in production and through urls.py in 
dev.)

Original comment by mand...@gmail.com on 3 May 2009 at 6:03

GoogleCodeExporter commented 9 years ago
I've given you superuser permissions at dev.news21.com so that you can
login to the admin

What you say makes sense.  Here are the settings that I have:

Alias /site_media/
/home/jetynan/sites/dev.news21.com/projects/django-newsroom/newsroom_project/med
ia/
Alias /admin_media/
/home/jetynan/sites/dev.news21.com/projects/pinax-env/lib/python2.5/site-package
s/django/contrib/admin/media/

Strange thing is that photologue is saving files to:

/home/jetynan/sites/dev.news21.com/projects/django-newsroom/newsroom_project/sit
e_media/photologue

If I go into the shell under pinax-env I get the following error:

/usr/lib/python2.5/site-packages/pytz/__init__.py:32: UserWarning:
Module photologue was already imported from
/home/jetynan/sites/dev.news21.com/projects/django-newsroom/newsroom_project/app
s/photologue/__init__.pyc,
but 
/home/jetynan/sites/dev.news21.com/projects/pinax-env/lib/python2.5/site-package
s
is being added to sys.path
 from pkg_resources import resource_stream
/usr/lib/python2.5/site-packages/pytz/__init__.py:32: UserWarning:
Module _mysql was already imported from
/var/lib/python-support/python2.5/_mysql.so, but
/var/lib/python-support/python2.5 is being added to sys.path
 from pkg_resources import resource_stream

So there might be an issue with the dev install.

Original comment by jgty...@gmail.com on 3 May 2009 at 8:27

GoogleCodeExporter commented 9 years ago
I get some of those warnings in my dev environment too. I think it's from 
having two photologues installed.  It's 
just warning you that there are two modules and one is overriding.  Pinax uses 
a different version on photologue 
so we have our override in the apps directory in our project.  I think this is 
ok. 

Now why photologue is looking for a diretory named site_media and how to fix 
that I'll have to get back to you...

Original comment by mand...@gmail.com on 4 May 2009 at 6:44

GoogleCodeExporter commented 9 years ago

Original comment by mand...@gmail.com on 4 May 2009 at 6:44

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago

Original comment by jgty...@gmail.com on 7 May 2009 at 8:25

GoogleCodeExporter commented 9 years ago
extra photologue is gone, moved to photos module.

Original comment by mand...@gmail.com on 13 May 2009 at 6:40

GoogleCodeExporter commented 9 years ago
Hi, I would appreciate if somebody can explain me how the error is finally 
resolved ?

Original comment by kint...@gmail.com on 24 Jan 2011 at 2:33

GoogleCodeExporter commented 9 years ago
Hi, I don't really have an answer for you. I think what solved this photologue 
issue was upgrading the module or integrating it into a different module.  

This project is pretty old and hasn't been dormant for a while, it should get 
updated with the latest  pinax base ideally.  This project will probably be 
sidelined for a while.  If you would like to help out or discuss further please 
join the group ... http://groups.google.com/group/django-newsroom

Original comment by mand...@gmail.com on 24 Jan 2011 at 4:39