Hi Ludovic,
> Hi, > > Before 1.5 release of HAProxy, I used Nginx for SSL and serve static files. > But now, I use only Nginx to serve static files, because I've better > performances with HAProxy for SSL. > > I know that HAProxy is only to proxy queries, but I've tried to server > a static file with HAProxy with monitor-uri and errorfile in my config > file: > > listen http-webservices > bind :8080 > monitor-uri /c > errorfile 200 /etc/haproxy/errorfiles/200.http > > It works pretty well, better performances than Nginx with cache enabled > (based on my benchmarks with Weighttp). Thats because the errorfile is read at startup and kept in memory. If you replace or update that file, HAProxy will still serve the old file it has in memory. You cannot compare this with regular file serving as nginx does it. I'm sure nginx performance is similar when you serve content as errorfile from memory. > But, it isn't really useable, I can only serve one static file by > frontend/listen. > > With 1.5 release, HAProxy is now capable to replace a Web server in > most cases, I've connected HAProxy directly with my Python daemons. If python daemons include a http server, sure. But that doesn't mean HAproxy is the webserver, it means that Python is the webserver. > Any plans to support static files ? > I know that HAProxy wasn't designed for that, but I've the feeling that > HAProxy could do that better than others Web servers. I don't really agree, but this is not the first request for local file system access, as mentioned by Willy in the Roadmap for 1.6 thread: http://marc.info/?l=haproxy&m=140630935820775&w=1 Regards, Lukas

