Skip to content

(aws-ec2): Support Amazon Linux 2023 as a first-class option for BastionHostLinux #29493

@blimmer

Description

@blimmer

Describe the feature

Today, the excellent BastionHostLinux construct defaults to an Amazon Linux 2 base image:

/**
* The machine image to use, assumed to have SSM Agent preinstalled.
*
* @default - An Amazon Linux 2 image which is kept up-to-date automatically (the instance
* may be replaced on every deployment) and already has SSM Agent installed.
*/
readonly machineImage?: IMachineImage;

However, Amazon Linux 2 will hit end of life in June 2025.

I see that I can pass my own MachineImage, but it'd be nice if there was a first-class flag to opt-in.

Use Case

It'd be nice to still be able to use BastionHostLinux, but use the newer Amazon Linux so I don't have to worry about upgrading next year.

Proposed Solution

It'd probably be a good idea to introduce a new feature flag and plan to automatically opt people into Amazon Linux 2023 on the next major version.

Other Information

No response

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change

CDK version used

2.132.1

Environment details (OS name and version, etc.)

macOS sonoma

Metadata

Metadata

Assignees

No one assigned

    Labels

    @aws-cdk/aws-ec2Related to Amazon Elastic Compute Cloudeffort/smallSmall work item – less than a day of effortfeature-requestA feature should be added or improved.p2

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions