Greetings. I'm not sure if this is a web.py specific error, or
something more with Apache. I am trying to use a simple .htaccess file
to protect my static folder.
The application is here: /var/www/myapp/
And the static folder is: /var/www/myapp/static/
The .htaccess file in the static folder is:
AuthUserFile /path/to/.htpasswd
AuthType Basic
AuthName "Protected Dir"
Require valid-user
When the .htaccess file is present, any file in the directory gives a
404 error, without .htaccess, it works fine. I suspect that something
with the mod_rewrite in the root folder (myapp/) is interfering and
causing an infinite loop, but I'm not familiar enough with Apache to
determine what this is.
The root web.py .htaccess is:
Options +ExecCGI
AddHandler cgi-script .py
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ /application.py/$1 [L]
</IfModule>
I've double checked that the path to the .htpasswd file is correct.
Web.py is running as a plain CGI (for now, will go to FCGI later). I'm
using Dreamhost, so I don't have access to httpd.conf.
Thanks!
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"web.py" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/webpy?hl=en
-~----------~----~----~----~------~----~------~--~---