AWS Fundamentals Logo
AWS Fundamentals
L2 Construct

Addon

Represents an Amazon EKS Add-On.

Import

import { Addon } from 'aws-cdk-lib/aws-eks';

Or use the module namespace:

import * as eks from 'aws-cdk-lib/aws-eks';
// eks.Addon

Properties

Configuration passed to the constructor as AddonProps.

addonNameRequired
string

Name of the Add-On.

clusterRequired
ICluster

The EKS cluster the Add-On is associated with.

addonVersionOptional
string

Version of the Add-On. You can check all available versions with describe-addon-versions. For example, this lists all available versions for the `eks-pod-identity-agent` addon: $ aws eks describe-addon-versions --addon-name eks-pod-identity-agent \ --query 'addons[*].addonVersions[*].addonVersion'

Default: the latest version.

configurationValuesOptional
{ [key: string]: any }

The configuration values for the Add-on.

Default: - Use default configuration.

preserveOnDeleteOptional
boolean

Specifying this option preserves the add-on software on your cluster but Amazon EKS stops managing any settings for the add-on. If an IAM account is associated with the add-on, it isn't removed.

Default: true

removalPolicyOptional
RemovalPolicy

The removal policy applied to the EKS add-on. The removal policy controls what happens to the resource if it stops being managed by CloudFormation. This can happen in one of three situations: - The resource is removed from the template, so CloudFormation stops managing it - A change to the resource is made that requires it to be replaced, so CloudFormation stops managing it - The stack is deleted, so CloudFormation stops managing all resources in it

Default: RemovalPolicy.DESTROY

Learn AWS the Practical Way

Our bi-weekly newsletter teaches hands-on AWS fundamentals. No certification fluff - just practical knowledge.

Subscribe to Newsletter