[Mongrel] Basic authentication with Apache and Mongrel

Matte Edens matte at ruckuswireless.com
Mon Mar 12 20:54:07 EDT 2007

I don't see the difference with this and a simple static apache site.  
It's still Apache in front of the proxy (as the proxy) doing the auth.  
I'm doing it.  That is if you're not involved with a complicated 
multi-server setup.

Also, if you're using Rails, you can do basic auth with the 
"simple_http_auth" plugin.  FYI.  I've used it.  It's cool.  And easier, 
IMHO, than setting up users on the server side with htpasswd, etc.  but 
be careful if you've got an open SVN repository.


Niall O Broin wrote:
> I recently moved an app. from lighttpd + fastcgi to apache 2.2 +  
> mod_proxy_balancer + Mongrel. On lighttpd, I was using basic  
> authentication with a configuration like this:
> auth.backend = "htpasswd"
> auth.backend.htpasswd.userfile = "/path/to/htpasswd"
> auth.require = ("/" => ("method" => "basic", "realm" => "My Realm",  
> "require" => "valid-user"))
> which was nice and simple - just as simple as using basic auth. with  
> a static Apache site.
> Is there any way of doing such authentication with apache 2.2 +  
> mod_proxy_balancer + Mongrel ? All I've been able to find with google  
> suggests that I can't do this and I will require some app. level  
> authentication, and I really don't want to have to do that.

More information about the Mongrel-users mailing list