Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e939b20

Browse files
committed
fix: Return deprecation error when using WebRTC endpoint
Fixes #4126.
1 parent 2ca7214 commit e939b20

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

coderd/coderd.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -430,6 +430,14 @@ func New(options *Options) *API {
430430
r.Get("/pty", api.workspaceAgentPTY)
431431
r.Get("/connection", api.workspaceAgentConnection)
432432
r.Get("/coordinate", api.workspaceAgentClientCoordinate)
433+
// TODO: This can be removed in October. It allows for a friendly
434+
// error message when transitioning from WebRTC to Tailscale. See:
435+
// https://github.com/coder/coder/issues/4126
436+
r.Get("/dial", func(w http.ResponseWriter, r *http.Request) {
437+
httpapi.Write(w, http.StatusGone, codersdk.Response{
438+
Message: "Your Coder CLI is out of date, and requires v0.8.15+ to connect!",
439+
})
440+
})
433441
})
434442
})
435443
r.Route("/workspaceresources/{workspaceresource}", func(r chi.Router) {

0 commit comments

Comments
 (0)