title: How to set a timeout for establishing a connection using net.Dialer?
body: <p>For example if the server does not respond for more than 3 seconds, I neet to get an error or something specific.
  I search everything but only see the lifetime of the connection (net.Dialer.Timeout / net.Dialer.Deadline) but neet to limit limit exactly the <strong>establishing</strong> time.</p>
  <p>Now my code like</p>
  <pre><code>dialer := net.Dialer{LocalAddr: net.TCPAddr{IP:&quot;192.168.1.68&quot;, Port:35030}}
  conn, err := tls.DialWithDialer(dialer, &quot;tcp&quot;, &quot;123.45.67.89&quot;, &amp;tls.Config{...})
  </code></pre>
  <p>Thanks!</p>