More explicit errors on TLS failure.

When getting an HTTP connection error different than connection refused,
issue a warning about connecting to TLS enabled daemons with no
TLSConfig, similar to what the Docker CLI is doing.

Signed-off-by: Andrea Luzzardi <aluzzardi@gmail.com>
Unfortunately, not. I agree that it's very ugly and tt's the same hack used in the Docker CLI.
Basically the error is thrown deep down the stack (e.g. NOT by the http client).

I've been trying to check the syscall error (ECONNREFUSED), but unsuccessfully.

If you think this is too hackish, I'm okay with dropping the PR.