Support for `heroku-agent` [1]

This supports communication with heroku-agent by downgrading the
connection to HTTP if communicating over a local Unix domain socket.

[1] https://github.com/brandur/heroku-agent