Class AmazonLinuxGeneration
What generation of Amazon Linux to use.
Inheritance
System.Object
AmazonLinuxGeneration
Namespace: Amazon.CDK.AWS.EC2
Assembly: Amazon.CDK.AWS.EC2.dll
Syntax (csharp)
public sealed class AmazonLinuxGeneration : Enum
Syntax (vb)
Public NotInheritable Class AmazonLinuxGeneration
Inherits
Enum
Remarks
ExampleMetadata: lit=test/example.images.lit.ts infused
Examples
// Pick a Windows edition to use
var windows = new WindowsImage(WindowsVersion.WINDOWS_SERVER_2019_ENGLISH_FULL_BASE);
// Pick the right Amazon Linux edition. All arguments shown are optional
// and will default to these values when omitted.
var amznLinux = new AmazonLinuxImage(new AmazonLinuxImageProps {
Generation = AmazonLinuxGeneration.AMAZON_LINUX,
Edition = AmazonLinuxEdition.STANDARD,
Virtualization = AmazonLinuxVirt.HVM,
Storage = AmazonLinuxStorage.GENERAL_PURPOSE
});
// For other custom (Linux) images, instantiate a `GenericLinuxImage` with
// a map giving the AMI to in for each region:
var linux = new GenericLinuxImage(new Dictionary<string, string> {
{ "us-east-1", "ami-97785bed" },
{ "eu-west-1", "ami-12345678" }
});
Synopsis
Fields
AMAZON_LINUX | Amazon Linux. |
AMAZON_LINUX_2 | Amazon Linux 2. |
AMAZON_LINUX_2022 | Amazon Linux 2022. |
value__ |
Fields
AMAZON_LINUX
Amazon Linux.
public const AmazonLinuxGeneration AMAZON_LINUX
Field Value
Type | Description |
---|---|
AmazonLinuxGeneration |
AMAZON_LINUX_2
Amazon Linux 2.
public const AmazonLinuxGeneration AMAZON_LINUX_2
Field Value
Type | Description |
---|---|
AmazonLinuxGeneration |
AMAZON_LINUX_2022
Amazon Linux 2022.
public const AmazonLinuxGeneration AMAZON_LINUX_2022
Field Value
Type | Description |
---|---|
AmazonLinuxGeneration |
value__
public int value__
Field Value
Type | Description |
---|---|
System.Int32 |