Skip to content

feat: add server flag to force DERP to use always websockets #9238

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 9 commits into from
Aug 24, 2023

Conversation

deansheather
Copy link
Member

@deansheather deansheather commented Aug 22, 2023

Adds coder server --derp-force-websockets flag which sets bool fields in the /api/v2/workspaceagents/:id/connection, /api/v2/workspaceagents/connection and /api/v2/workspaceagents/me/manifest endpoints.

Clients and agents will call (*magicsock.Conn).SetForceDERPWebsockets(v bool) to tell tailscale to always use WebSockets when connecting to any DERP server.

TODO:

  • coderd connections should call the function
  • wsproxy connections should call the function

Depends on coder/tailscale#35 (need to update go.mod)

Fixes #9237

@deansheather deansheather marked this pull request as ready for review August 23, 2023 11:34
@deansheather deansheather requested a review from coadler August 23, 2023 11:34
@deansheather deansheather enabled auto-merge (squash) August 24, 2023 17:05
@deansheather deansheather merged commit 64df076 into main Aug 24, 2023
@deansheather deansheather deleted the dean/server-derp-force-websockets branch August 24, 2023 17:22
@github-actions github-actions bot locked and limited conversation to collaborators Aug 24, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add flag to server to force all clients to use DERP over WebSockets by default
3 participants