import { ImageBuilder } from '@cloudadder/cdk-ec2-imagebuilder'
new ImageBuilder(scope: Construct, id: string, props: ImageBuilderProps)| Name | Type | Description |
|---|---|---|
scope* |
constructs.Construct |
No description. |
id* |
string |
No description. |
props* |
@cloudadder/cdk-ec2-imagebuilder.ImageBuilderProps |
No description. |
- Type:
constructs.Construct
- Type:
string
import { ImageBuilderProps } from '@cloudadder/cdk-ec2-imagebuilder'
const imageBuilderProps: ImageBuilderProps = { ... }| Name | Type | Description |
|---|---|---|
amiName* |
string |
The AMI name. |
componentsFolder* |
string |
Local folder name including path which contains the component yaml files. |
id* |
string |
The id to use as a name suffix to identify resources in AWS. |
securityGroupIds* |
string[] |
The securityGroupIds to use for the build. |
subnetId* |
string |
The subnet id to use for the build. |
version* |
string |
Version to use in the metadata of the build. |
componentsManagedByAWS |
string[] |
A list of AWS managed component arns to be used in the image recipe. |
instanceTypes |
string[] |
The instance types to use for the build. |
parentImage |
string |
Parent AMI Image Arn. |
scheduleExpression |
string |
The scheduleExpression for creating a refresh schedule of the AMI in cron format 0 0 * * ? *. |
shareAccountIds |
string[] |
The account ids to share the AMI with. |
public readonly amiName: string;- Type:
string
The AMI name.
public readonly componentsFolder: string;- Type:
string
Local folder name including path which contains the component yaml files.
e.g. './src/components'
public readonly id: string;- Type:
string
The id to use as a name suffix to identify resources in AWS.
public readonly securityGroupIds: string[];- Type:
string[]
The securityGroupIds to use for the build.
A single subnet id is enough to allow access to the build instance. The subnet must support ssm agent installation
public readonly subnetId: string;- Type:
string
The subnet id to use for the build.
public readonly version: string;- Type:
string
Version to use in the metadata of the build.
AWS requires a version unique to the build, therefore incrementing the version number is required for each deployment.
public readonly componentsManagedByAWS: string[];- Type:
string[]
A list of AWS managed component arns to be used in the image recipe.
e.g. In the console under EC2 Image Builder->Components-reboot-linux you will find the arn of the reboot-linux component.
public readonly instanceTypes: string[];- Type:
string[] - Default:
[t3.medium]
The instance types to use for the build.
public readonly parentImage: string;- Type:
string - Default: the latest Amazon Linux 2 AMI
'arn:aws:imagebuilder:' + Stack.of(this).region + ':aws:image/amazon-linux-2-x86/x.x.x'
Parent AMI Image Arn.
public readonly scheduleExpression: string;- Type:
string - Default: No schedule
The scheduleExpression for creating a refresh schedule of the AMI in cron format 0 0 * * ? *.
public readonly shareAccountIds: string[];- Type:
string[]
The account ids to share the AMI with.