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

Commitea0c978

Browse files
committed
fix!: enforce agent names be case-insensitive-unique per-workspace
1 parent2a248b1 commitea0c978

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

‎provisioner/terraform/resources.go

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -215,10 +215,12 @@ func ConvertState(ctx context.Context, modules []*tfjson.StateModule, rawGraph s
215215
returnnil,xerrors.Errorf("decode agent attributes: %w",err)
216216
}
217217

218-
if_,ok:=agentNames[tfResource.Name];ok {
218+
// Agent names must be case-insensitive-unique, to be unamibuiguous in
219+
// `coder_app`s and CoderVPN DNS names.
220+
if_,ok:=agentNames[strings.ToLower(tfResource.Name)];ok {
219221
returnnil,xerrors.Errorf("duplicate agent name: %s",tfResource.Name)
220222
}
221-
agentNames[tfResource.Name]=struct{}{}
223+
agentNames[strings.ToLower(tfResource.Name)]=struct{}{}
222224

223225
// Handling for deprecated attributes. login_before_ready was replaced
224226
// by startup_script_behavior, but we still need to support it for

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp