`awsecs`: Golang - missing ecs optmized Bottlerocket images
- Dominant language
- TypeScript
- Stars
- 12.9k
- Forks
- 4.6k
- Avg merge
- 2d 3h
- Merged PRs (30d)
- 83
Description
### Describe the bug
Using the Golang CDK bindings, there is no `EcsOptimizedImage_Bottlerocket`. I only see the Amazon Linux ones and the Windows ones:
```
EcsOptimizedImage_AmazonLinux (options *EcsOptimizedImageOptions) EcsOptimizedImage
EcsOptimizedImage_AmazonLinux2 (hardwareType AmiHardwareType, options *EcsOptimizedImageOptions) EcsOptimizedImage
EcsOptimizedImage_Windows (windowsVersion WindowsOptimizedVersion, options *EcsOptimizedImageOptions) EcsOptimizedImage
```
https://github.com/aws/aws-cdk-go/blob/main/awscdk/awsecs/EcsOptimizedImage.go
However, I do see the correct binding in this repository in typescript:
https://github.com/aws/aws-cdk/blob/05a9fec6512bdddc387a7a5c98fa55f1ab3b5b64/packages/aws-cdk-lib/aws-ecs/lib/amis.ts#L288-L298
### Expected Behavior
I'd expect there to _also_ be the correct Bottlerocket ECS optimized ami in Golang as well:
```go
// The aws-ecs-1 variant of bottlerocket
EcsOptimizedImage_Bottlerocket (options *EcsOptimizedImageOptions) EcsOptimizedImage
```
### Current Behavior
Missing function in the `awsecs` Go library to the Bottlerocket optimized AMI
### Reproduction Steps
N/a
### Possible Solution
I thought the Go bindings were generated from this Typescript codebase. So I'm surprised to find that the `awsecs` Go package is missing the Bottlerocket AMIs. These should be added since the `aws-ecs-1` variant is supported by ECS.
### Additional Information/Context
_No response_
### CDK CLI Version
2.78.0 (build 8e95c37)
### Framework Version
_No response_
### Node.js Version
18.16.0
### OS
Linux x86_64 ubuntu
### Language
Go
### Language Version
go version go1.20.4 linux/amd64
### Other information
_No response_
Contributor guide
Research direction
Compare awscdk/awsecs/EcsOptimizedImage.go with the Bottlerocket definitions in packages/aws-cdk-lib/aws-ecs/lib/amis.ts at lines 288-298. Confirm how the Go bindings expose the existing Amazon Linux and Windows images, then add the missing Bottlerocket binding consistently. Done means the awsecs Go library exposes EcsOptimizedImage_Bottlerocket for the aws-ecs-1 variant.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, go, typescript
- Domain
- cloud
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100