On Fri, Jan 30, 2009 at 7:40 PM, Michael Fortson <[email protected]> wrote:
> It doesn't look like this is supported yet since acl only supports
> block, but I'd like to route incoming requests based on the URI.

That's extremely basic, actually. On paths:

  acl static path_beg /images/ /stylesheets/ /javascripts/
  use_backend webserver if static
  default_backend mongrel

On hosts:

  acl site1 hdr_reg(host) site1.com
  acl site2 hdr_reg(host) site2.com
  use_backend web1 if site1
  use_backend web2 if site2

On path *and* host:

  use_backend web1 if site1 static
  use_backend web2 if site2 static

Everything is covered here:

  http://haproxy.1wt.eu/download/1.3/doc/configuration.txt

Alexander.

Reply via email to