serving static files

1 view
Skip to first unread message

axh...@gmail.com

unread,
Mar 24, 2009, 5:48:24 PM3/24/09
to juno-framework
Hi,

I believe the code used to serve static file needs to be modified
from

if not realfile.startswith(config('static_root')):
notfound("that file could not be found/served")


to:

if not realfile.startswith(os.path.realpath(config('static_root'))):
notfound("that file could not be found/served")


Ashish

Brian

unread,
Mar 24, 2009, 6:47:30 PM3/24/09
to juno-framework
Good catch, I'll change it. It seems to only be an issue if the
static/ directory is a symlink - out of curiosity, is that how you
have it set up?

Brian

axh...@gmail.com

unread,
Mar 24, 2009, 6:55:13 PM3/24/09
to juno-framework
Hi Brian,

I have static as a proper directory. I have

app/
static/
juno.py
webapp.py


I don't install to site-packages and have sessions and templates
turned off.

Ashish
Reply all
Reply to author
Forward
0 new messages