From 8fb84be6b015dbac8ce3bb26faaf7fb828d0751a Mon Sep 17 00:00:00 2001 From: Spike Curtis Date: Thu, 27 Jun 2024 14:44:09 +0400 Subject: [PATCH] fix: modify workspacesdk to ask for tailnet API 2.0 --- codersdk/workspacesdk/workspacesdk.go | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/codersdk/workspacesdk/workspacesdk.go b/codersdk/workspacesdk/workspacesdk.go index f1e3bd67ea3dc..0cc4d1a6a378b 100644 --- a/codersdk/workspacesdk/workspacesdk.go +++ b/codersdk/workspacesdk/workspacesdk.go @@ -21,7 +21,6 @@ import ( "cdr.dev/slog" "github.com/coder/coder/v2/codersdk" "github.com/coder/coder/v2/tailnet" - "github.com/coder/coder/v2/tailnet/proto" ) // AgentIP is a static IPv6 address with the Tailscale prefix that is used to route @@ -239,7 +238,15 @@ func (c *Client) DialAgent(dialCtx context.Context, agentID uuid.UUID, options * return nil, xerrors.Errorf("parse url: %w", err) } q := coordinateURL.Query() - q.Add("version", proto.CurrentVersion.String()) + // TODO (ethanndickson) - the current version includes 2 additions we don't currently use: + // + // 2.1 GetAnnouncementBanners on the Agent API (version locked to Tailnet API) + // 2.2 PostTelemetry on the Tailnet API + // + // So, asking for API 2.2 just makes us incompatible back level servers, for no real benefit. + // As a temporary measure, we'll specifically ask for API version 2.0 until we implement sending + // telemetry. + q.Add("version", "2.0") coordinateURL.RawQuery = q.Encode() connector := runTailnetAPIConnector(ctx, options.Logger, pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy