title: how to define HTTP health check in a consul container for a service on the same host?
body: <p>We are using a consul agent on a host that also runs a service. (RabbitMQ)
  To verify that the service is ready we have defined a curl based health check.
  however, we are using the registrator to inject this check using env variable.
  SERVICE_CHECK_SCRIPT=curl <code>hostname</code>:15672/....</p>
  
  <p>problem is, we've also told the consul-agent that its hostname is the same as the host.
  (We must have this feature since we want to see the correct hostname registered with the consul cluster.</p>
  
  <p>When the consul agent runs the health check, it looks for the URL on its own container...
  this obviously fails...
  does anybody knows how to define this health check (we are using mesos to do it) so that curl will attempt to connect to the right ip?    </p>