Your tcp_keepalive is killing it inside Docker. Remove it or set it to None.
None
Everything else (DNS, credentials, TCP) is fine.