A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/coder/coder/commit/99d124e27612babe284c6c0f935c0a122f435275 below:

enable devcontainers by default (#18533) · coder/coder@99d124e · GitHub

@@ -89,9 +89,8 @@ type Options struct {

89 89

ServiceBannerRefreshInterval time.Duration

90 90

BlockFileTransfer bool

91 91

Execer agentexec.Execer

92 - 93 -

ExperimentalDevcontainersEnabled bool

94 -

ContainerAPIOptions []agentcontainers.Option // Enable ExperimentalDevcontainersEnabled for these to be effective.

92 +

Devcontainers bool

93 +

DevcontainerAPIOptions []agentcontainers.Option // Enable Devcontainers for these to be effective.

95 94

}

96 95 97 96

type Client interface {

@@ -190,8 +189,8 @@ func New(options Options) Agent {

190 189

metrics: newAgentMetrics(prometheusRegistry),

191 190

execer: options.Execer,

192 191 193 -

experimentalDevcontainersEnabled: options.ExperimentalDevcontainersEnabled,

194 -

containerAPIOptions: options.ContainerAPIOptions,

192 +

devcontainers: options.Devcontainers,

193 +

containerAPIOptions: options.DevcontainerAPIOptions,

195 194

}

196 195

// Initially, we have a closed channel, reflecting the fact that we are not initially connected.

197 196

// Each time we connect we replace the channel (while holding the closeMutex) with a new one

@@ -272,9 +271,9 @@ type agent struct {

272 271

metrics *agentMetrics

273 272

execer agentexec.Execer

274 273 275 -

experimentalDevcontainersEnabled bool

276 -

containerAPIOptions []agentcontainers.Option

277 -

containerAPI atomic.Pointer[agentcontainers.API] // Set by apiHandler.

274 +

devcontainers bool

275 +

containerAPIOptions []agentcontainers.Option

276 +

containerAPI atomic.Pointer[agentcontainers.API] // Set by apiHandler.

278 277

}

279 278 280 279

func (a *agent) TailnetConn() *tailnet.Conn {

@@ -311,7 +310,7 @@ func (a *agent) init() {

311 310

return a.reportConnection(id, connectionType, ip)

312 311

},

313 312 314 -

ExperimentalDevContainersEnabled: a.experimentalDevcontainersEnabled,

313 +

ExperimentalContainers: a.devcontainers,

315 314

})

316 315

if err != nil {

317 316

panic(err)

@@ -340,7 +339,7 @@ func (a *agent) init() {

340 339

a.metrics.connectionsTotal, a.metrics.reconnectingPTYErrors,

341 340

a.reconnectingPTYTimeout,

342 341

func(s *reconnectingpty.Server) {

343 -

s.ExperimentalDevcontainersEnabled = a.experimentalDevcontainersEnabled

342 +

s.ExperimentalContainers = a.devcontainers

344 343

},

345 344

)

346 345

go a.runLoop()

@@ -1087,9 +1086,9 @@ func (a *agent) handleManifest(manifestOK *checkpoint) func(ctx context.Context,

1087 1086

slog.F("parent_id", manifest.ParentID),

1088 1087

slog.F("agent_id", manifest.AgentID),

1089 1088

)

1090 -

if a.experimentalDevcontainersEnabled {

1089 +

if a.devcontainers {

1091 1090

a.logger.Info(ctx, "devcontainers are not supported on sub agents, disabling feature")

1092 -

a.experimentalDevcontainersEnabled = false

1091 +

a.devcontainers = false

1093 1092

}

1094 1093

}

1095 1094

a.client.RewriteDERPMap(manifest.DERPMap)

@@ -1145,7 +1144,7 @@ func (a *agent) handleManifest(manifestOK *checkpoint) func(ctx context.Context,

1145 1144

scripts = manifest.Scripts

1146 1145

scriptRunnerOpts []agentscripts.InitOption

1147 1146

)

1148 -

if a.experimentalDevcontainersEnabled {

1147 +

if a.devcontainers {

1149 1148

var dcScripts []codersdk.WorkspaceAgentScript

1150 1149

scripts, dcScripts = agentcontainers.ExtractAndInitializeDevcontainerScripts(manifest.Devcontainers, scripts)

1151 1150

// See ExtractAndInitializeDevcontainerScripts for motivation


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4