You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We need a way for our various clients like plugins/IDE extensions and the CLI to be able to determine if they should use Coder Connect when connecting to a workspace.
For this we'll use DNS queries. DNS (unlike, say a ping or HTTP request to a well known HTTP endpoint on the Coder Connect tunnel) has the property of returning a definite result in both cases whether Coder Connect is running (AAAA record) or not (NXDOMAIN).
Ensure DNS TTL for Coder Connect records is 2 seconds or less, to avoid cached responses giving incorrect results
Add a generic record is.coder.connect.enabled.right.now--.<suffix> which returns the tunnel service address. This address can be used when you want to know if Coder Connect is running, but are not trying to connect to a specific known workspace.
is.coder.connect.enabled.right.now--.<suffix> has 6 label components and double-dashes which are not allowed in workspace names. This ensures it can never collide with a legitimate workspace hostname.