Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit9164618

Browse files
johnstcnkylecarbs
authored andcommitted
Revert "fix: Use Terraform address to index resource + agent association (#1577)" (#1585)
This reverts commitf3fe2a0.
1 parent544ee9b commit9164618

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

‎provisioner/terraform/provision.go

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -357,10 +357,11 @@ func parseTerraformPlan(ctx context.Context, terraform *tfexec.Terraform, planfi
357357
ifresource.Type=="coder_agent"||resource.Type=="coder_agent_instance" {
358358
continue
359359
}
360+
resourceKey:=strings.Join([]string{resource.Type,resource.Name},".")
360361
resources=append(resources,&proto.Resource{
361362
Name:resource.Name,
362363
Type:resource.Type,
363-
Agents:findAgents(resourceDependencies,agents,resource.Address),
364+
Agents:findAgents(resourceDependencies,agents,resourceKey),
364365
})
365366
}
366367

@@ -497,7 +498,8 @@ func parseTerraformApply(ctx context.Context, terraform *tfexec.Terraform, state
497498
ifresource.Type=="coder_agent"||resource.Type=="coder_agent_instance" {
498499
continue
499500
}
500-
resourceAgents:=findAgents(resourceDependencies,agents,resource.Address)
501+
resourceKey:=strings.Join([]string{resource.Type,resource.Name},".")
502+
resourceAgents:=findAgents(resourceDependencies,agents,resourceKey)
501503
for_,agent:=rangeresourceAgents {
502504
// Didn't use instance identity.
503505
ifagent.GetToken()!="" {

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp