title: Redirect on HAProxy
body: <p>I'm trying to replicate the following configuration made in apache in HAProxy, but so far without success.</p>
  
  <pre><code>&lt;VirtualHost *:80&gt;
      ProxyPreserveHost On
      ServerName alpha.app.int
      ProxyPass / http://127.0.0.1:8080/app/
      ProxyPassReverse / http://127.0.0.1:8080/app/
  &lt;/VirtualHost&gt;
  </code></pre>
  
  <p>What I'm trying to do is when the address 'alpha.app.int' is accessed, HAProxy automatically directs all requests for my application in JBoss that is listening on '127.0.0.1:8080/app/', but when I try to access through the url previously mentioned I end up falling on the configuration screen of JBoss and not in my application, I can only see it by accessing 'alpha.app.int/app/'. Does anyone have any suggestions on how to do this?</p>
  
  <p>HAProxy Settings:</p>
  
  <pre><code>frontend app
      bind *:80
      mode http
      default_backend frontend app
  
  backend app
      mode http
      option forwardfor
      server alpha 127.0.0.1:8080/app
  </code></pre>