Class CfnAddon
java.lang.Object
software.amazon.jsii.JsiiObject
software.constructs.Construct
software.amazon.awscdk.CfnElement
software.amazon.awscdk.CfnRefElement
software.amazon.awscdk.CfnResource
software.amazon.awscdk.services.eks.CfnAddon
- All Implemented Interfaces:
IEnvironmentAware,IInspectable,ITaggable,IAddonRef,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
@Generated(value="jsii-pacmak/1.118.0 (build 02eec31)",
date="2025-11-10T13:40:05.550Z")
@Stability(Stable)
public class CfnAddon
extends CfnResource
implements IInspectable, IAddonRef, ITaggable
Creates an Amazon EKS add-on.
Amazon EKS add-ons help to automate the provisioning and lifecycle management of common operational software for Amazon EKS clusters. For more information, see Amazon EKS add-ons in the Amazon EKS User Guide .
Example:
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import software.amazon.awscdk.services.eks.*;
CfnAddon cfnAddon = CfnAddon.Builder.create(this, "MyCfnAddon")
.addonName("addonName")
.clusterName("clusterName")
// the properties below are optional
.addonVersion("addonVersion")
.configurationValues("configurationValues")
.namespaceConfig(NamespaceConfigProperty.builder()
.namespace("namespace")
.build())
.podIdentityAssociations(List.of(PodIdentityAssociationProperty.builder()
.roleArn("roleArn")
.serviceAccount("serviceAccount")
.build()))
.preserveOnDelete(false)
.resolveConflicts("resolveConflicts")
.serviceAccountRoleArn("serviceAccountRoleArn")
.tags(List.of(CfnTag.builder()
.key("key")
.value("value")
.build()))
.build();
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classA fluent builder forCfnAddon.static interfaceThe custom namespace configuration to use with the add-on.static interfaceAmazon EKS Pod Identity associations provide the ability to manage credentials for your applications, similar to the way that Amazon EC2 instance profiles provide credentials to Amazon EC2 instances.Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.amazon.awscdk.services.eks.IAddonRef
IAddonRef.Jsii$Default, IAddonRef.Jsii$ProxyNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.IInspectable
IInspectable.Jsii$Default, IInspectable.Jsii$ProxyNested classes/interfaces inherited from interface software.amazon.awscdk.ITaggable
ITaggable.Jsii$Default, ITaggable.Jsii$Proxy -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringThe CloudFormation resource type name for this resource class. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedCfnAddon(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedCfnAddon(software.amazon.jsii.JsiiObjectRef objRef) CfnAddon(software.constructs.Construct scope, String id, CfnAddonProps props) -
Method Summary
Modifier and TypeMethodDescriptionThe name of the add-on.A reference to a Addon resource.The version of the add-on.The ARN of the add-on, such asarn:aws:eks:us-west-2:111122223333:addon/1-19/vpc-cni/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx.The name of your cluster.The configuration values that you provided.The namespace configuration for the addon.An array of EKS Pod Identity associations owned by the add-on.Specifying this option preserves the add-on software on your cluster but Amazon EKS stops managing any settings for the add-on.How to resolve field value conflicts for an Amazon EKS add-on.The Amazon Resource Name (ARN) of an existing IAM role to bind to the add-on's service account.getTags()Tag Manager which manages the tags for this resource.The metadata that you apply to the add-on to assist with categorization and organization.voidinspect(TreeInspector inspector) Examines the CloudFormation resource and discloses attributes.renderProperties(Map<String, Object> props) voidsetAddonName(String value) The name of the add-on.voidsetAddonVersion(String value) The version of the add-on.voidsetClusterName(String value) The name of your cluster.voidsetConfigurationValues(String value) The configuration values that you provided.voidsetNamespaceConfig(IResolvable value) The namespace configuration for the addon.voidThe namespace configuration for the addon.voidsetPodIdentityAssociations(List<Object> value) An array of EKS Pod Identity associations owned by the add-on.voidAn array of EKS Pod Identity associations owned by the add-on.voidsetPreserveOnDelete(Boolean value) Specifying this option preserves the add-on software on your cluster but Amazon EKS stops managing any settings for the add-on.voidsetPreserveOnDelete(IResolvable value) Specifying this option preserves the add-on software on your cluster but Amazon EKS stops managing any settings for the add-on.voidsetResolveConflicts(String value) How to resolve field value conflicts for an Amazon EKS add-on.voidsetServiceAccountRoleArn(String value) The Amazon Resource Name (ARN) of an existing IAM role to bind to the add-on's service account.voidsetTagsRaw(List<CfnTag> value) The metadata that you apply to the add-on to assist with categorization and organization.Methods inherited from class software.amazon.awscdk.CfnResource
addDeletionOverride, addDependency, addDependsOn, addMetadata, addOverride, addPropertyDeletionOverride, addPropertyOverride, applyRemovalPolicy, applyRemovalPolicy, applyRemovalPolicy, getAtt, getAtt, getCfnOptions, getCfnResourceType, getEnv, getMetadata, getUpdatedProperites, getUpdatedProperties, isCfnResource, obtainDependencies, obtainResourceDependencies, removeDependency, replaceDependency, shouldSynthesize, toString, validatePropertiesMethods inherited from class software.amazon.awscdk.CfnRefElement
getRefMethods inherited from class software.amazon.awscdk.CfnElement
getCreationStack, getLogicalId, getStack, isCfnElement, overrideLogicalIdMethods inherited from class software.constructs.Construct
getNode, isConstructMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface software.constructs.IConstruct
getNodeMethods inherited from interface software.amazon.awscdk.IEnvironmentAware
getEnvMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Field Details
-
CFN_RESOURCE_TYPE_NAME
The CloudFormation resource type name for this resource class.
-
-
Constructor Details
-
CfnAddon
protected CfnAddon(software.amazon.jsii.JsiiObjectRef objRef) -
CfnAddon
protected CfnAddon(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
CfnAddon
@Stability(Stable) public CfnAddon(@NotNull software.constructs.Construct scope, @NotNull String id, @NotNull CfnAddonProps props) - Parameters:
scope- Scope in which this resource is defined. This parameter is required.id- Construct identifier for this resource (unique in its scope). This parameter is required.props- Resource properties. This parameter is required.
-
-
Method Details
-
inspect
Examines the CloudFormation resource and discloses attributes.- Specified by:
inspectin interfaceIInspectable- Parameters:
inspector- tree inspector to collect and process attributes. This parameter is required.
-
renderProperties
@Stability(Stable) @NotNull protected Map<String,Object> renderProperties(@NotNull Map<String, Object> props) - Overrides:
renderPropertiesin classCfnResource- Parameters:
props- This parameter is required.
-
getAddonRef
A reference to a Addon resource.- Specified by:
getAddonRefin interfaceIAddonRef
-
getAttrArn
The ARN of the add-on, such asarn:aws:eks:us-west-2:111122223333:addon/1-19/vpc-cni/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx. -
getCfnProperties
- Overrides:
getCfnPropertiesin classCfnResource
-
getTags
Tag Manager which manages the tags for this resource. -
getAddonName
The name of the add-on. -
setAddonName
The name of the add-on. -
getClusterName
The name of your cluster. -
setClusterName
The name of your cluster. -
getAddonVersion
The version of the add-on. -
setAddonVersion
The version of the add-on. -
getConfigurationValues
The configuration values that you provided. -
setConfigurationValues
The configuration values that you provided. -
getNamespaceConfig
The namespace configuration for the addon.Returns union: either
IResolvableorCfnAddon.NamespaceConfigProperty -
setNamespaceConfig
The namespace configuration for the addon. -
setNamespaceConfig
The namespace configuration for the addon. -
getPodIdentityAssociations
An array of EKS Pod Identity associations owned by the add-on.Returns union: either
IResolvableor Listinvalid input: '<'eitherIResolvableorCfnAddon.PodIdentityAssociationProperty> -
setPodIdentityAssociations
An array of EKS Pod Identity associations owned by the add-on. -
setPodIdentityAssociations
An array of EKS Pod Identity associations owned by the add-on. -
getPreserveOnDelete
Specifying this option preserves the add-on software on your cluster but Amazon EKS stops managing any settings for the add-on.Returns union: either
BooleanorIResolvable -
setPreserveOnDelete
Specifying this option preserves the add-on software on your cluster but Amazon EKS stops managing any settings for the add-on. -
setPreserveOnDelete
Specifying this option preserves the add-on software on your cluster but Amazon EKS stops managing any settings for the add-on. -
getResolveConflicts
How to resolve field value conflicts for an Amazon EKS add-on. -
setResolveConflicts
How to resolve field value conflicts for an Amazon EKS add-on. -
getServiceAccountRoleArn
The Amazon Resource Name (ARN) of an existing IAM role to bind to the add-on's service account. -
setServiceAccountRoleArn
The Amazon Resource Name (ARN) of an existing IAM role to bind to the add-on's service account. -
getTagsRaw
The metadata that you apply to the add-on to assist with categorization and organization. -
setTagsRaw
The metadata that you apply to the add-on to assist with categorization and organization.
-