Skip to content

Commit 446043e

Browse files
authored
fix: LaunchTemplates to set InstanceMetadataTags as "disabled" (#503)
* chore: ignore local files Signed-off-by: Kevin Downey <[email protected]> * fix: set InstanceMetadataTags "disabled" Signed-off-by: Kevin Downey <[email protected]> * chore: add tests for InstanceMetadataTags disabled Signed-off-by: Kevin Downey <[email protected]> * chore: run make manifests Signed-off-by: Kevin Downey <[email protected]> --------- Signed-off-by: Kevin Downey <[email protected]>
1 parent 37a9535 commit 446043e

File tree

4 files changed

+428
-2
lines changed

4 files changed

+428
-2
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,4 @@ vendor/*
99
*.idea
1010
.windsurfrules
1111
.qodo
12+
.tool-versions

config/crd/bases/instancemgr.keikoproj.io_instancegroups.yaml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,6 @@ spec:
7878
properties:
7979
configuration:
8080
properties:
81-
nodeConfig:
82-
type: string
8381
bootstrapArguments:
8482
type: string
8583
bootstrapOptions:

controllers/provisioners/eks/scaling/launchtemplate.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -364,6 +364,7 @@ func (lt *LaunchTemplate) metadataOptions(input *v1alpha1.MetadataOptions) *ec2.
364364
HttpEndpoint: aws.String(input.HttpEndpoint),
365365
HttpPutResponseHopLimit: aws.Int64(input.HttpPutHopLimit),
366366
HttpTokens: aws.String(input.HttpTokens),
367+
InstanceMetadataTags: aws.String("disabled"), // set disabled by default
367368
}
368369
}
369370

@@ -375,6 +376,7 @@ func (lt *LaunchTemplate) metadataOptionsRequest(input *v1alpha1.MetadataOptions
375376
HttpEndpoint: aws.String(input.HttpEndpoint),
376377
HttpPutResponseHopLimit: aws.Int64(input.HttpPutHopLimit),
377378
HttpTokens: aws.String(input.HttpTokens),
379+
InstanceMetadataTags: aws.String("disabled"), // set disabled by default
378380
}
379381
}
380382

0 commit comments

Comments
 (0)