Electronics & Programming

develissimo

Open Source electronics development and programming

  • You are not logged in.

#1 Jan. 11, 2011 12:56:52

T.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

default _ storage path


hello
may we use default storage to write outside of project or only in media
because i can writ in media path ...

my porject : /home/user/project

and i 'd like to write in

/var/www/myoutputdirectory own by what ever you want but i've truy www-data
and the user in my WSGIDaemon in apache conf for mod wsgi ...

so i 've SuspiciousOperation

attempte access '/var/www/myoutpudirectory/myfilename ' denied

--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group athttp://groups.google.com/group/django-users?hl=en.

Offline

#2 Jan. 11, 2011 15:20:55

u.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

default _ storage path


One solution is to create your own storage to upload files outside
MEDIA folder.
Also you will have to write own views to rwtrieve and display these
files.
Or you have to configure your server to serve static files in the way
you want.

Maybe there's better solution, but i did it this way.

Radovan

On 11. Jan, 13:56 h., Tonton <to.ton...@gmail.com> wrote:
> hello
> may we use default storage to write outside of project or only in media
> because i can writ in media path ...
>
> my porject : /home/user/project
>
> and i 'd like to write in
>
> /var/www/myoutputdirectory  own by what ever you want but i've truy www-data
> and the user in my WSGIDaemon in apache conf for mod wsgi ...
>
> so i 've SuspiciousOperation
>
> attempte access '/var/www/myoutpudirectory/myfilename ' denied

--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group athttp://groups.google.com/group/django-users?hl=en.

Offline

#3 Jan. 11, 2011 16:10:37

prasad i.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

default _ storage path


Give www-data rwx permission /va/www/dir and start the application
using the user who is member of www-data

On Jan 11, 4:56 am, Tonton <to.ton...@gmail.com> wrote:
> hello
> may we use default storage to write outside of project or only in media
> because i can writ in media path ...
>
> my porject : /home/user/project
>
> and i 'd like to write in
>
> /var/www/myoutputdirectory  own by what ever you want but i've truy www-data
> and the user in my WSGIDaemon in apache conf for mod wsgi ...
>
> so i 've SuspiciousOperation
>
> attempte access '/var/www/myoutpudirectory/myfilename ' denied

--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group athttp://groups.google.com/group/django-users?hl=en.

Offline

#4 Jan. 12, 2011 09:03:09

T.
Registered: 2009-11-02
Reputation: +  0  -
Profile   Send e-mail  

default _ storage path


thanks but i do like that

i saved file i generate in /media/directory so the path is
path="directory/filename.ext"

and in var/www/ link ln-s /home/project/media/directory directory

so my other program could acces to configuration file in /var/www/directory
store in media in real !

regards
tonton

On Tue, Jan 11, 2011 at 5:10 PM, prasad iyer <p.c.i...@gmail.com> wrote:

> Give www-data rwx permission /va/www/dir and start the application
> using the user who is member of www-data
>
> On Jan 11, 4:56 am, Tonton <to.ton...@gmail.com> wrote:
> > hello
> > may we use default storage to write outside of project or only in media
> > because i can writ in media path ...
> >
> > my porject : /home/user/project
> >
> > and i 'd like to write in
> >
> > /var/www/myoutputdirectory own by what ever you want but i've truy
> www-data
> > and the user in my WSGIDaemon in apache conf for mod wsgi ...
> >
> > so i 've SuspiciousOperation
> >
> > attempte access '/var/www/myoutpudirectory/myfilename ' denied
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To post to this group, send email to django-us...@googlegroups.com.
> To unsubscribe from this group, send email to
> django-users+unsubscr...@googlegroups.com<django-users%2bunsubscr...@googlegroups.com>
> .
> For more options, visit this group at
>http://groups.google.com/group/django-users?hl=en.
>
>

--
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to
django-users+unsubscr...@googlegroups.com.
For more options, visit this group athttp://groups.google.com/group/django-users?hl=en.

Offline

Board footer

Moderator control

Enjoy the 18th of August
PoweredBy

The Forums are managed by develissimo stuff members, if you find any issues or misplaced content please help us to fix it. Thank you! Tell us via Contact Options
Leave a Message
Welcome to Develissimo Live Support