Class: AWSCDK::EKS::CfnAddonProps
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::EKS::CfnAddonProps
- Defined in:
- eks/cfn_addon_props.rb
Overview
Properties for defining a CfnAddon.
Instance Attribute Summary collapse
-
#addon_name ⇒ String
readonly
The name of the add-on.
-
#addon_version ⇒ String?
readonly
The version of the add-on.
-
#cluster_name ⇒ String
readonly
The name of your cluster.
-
#configuration_values ⇒ String?
readonly
The configuration values that you provided.
-
#namespace_config ⇒ AWSCDK::IResolvable, ...
readonly
The namespace configuration for the addon.
-
#pod_identity_associations ⇒ AWSCDK::IResolvable, ...
readonly
An array of EKS Pod Identity associations owned by the add-on.
-
#preserve_on_delete ⇒ Boolean, ...
readonly
Specifying this option preserves the add-on software on your cluster but Amazon EKS stops managing any settings for the add-on.
-
#resolve_conflicts ⇒ String?
readonly
How to resolve field value conflicts for an Amazon EKS add-on.
-
#service_account_role_arn ⇒ String, ...
readonly
The Amazon Resource Name (ARN) of an existing IAM role to bind to the add-on's service account.
-
#tags ⇒ Array<AWSCDK::CfnTag>?
readonly
The metadata that you apply to the add-on to assist with categorization and organization.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(addon_name:, cluster_name:, addon_version: nil, configuration_values: nil, namespace_config: nil, pod_identity_associations: nil, preserve_on_delete: nil, resolve_conflicts: nil, service_account_role_arn: nil, tags: nil) ⇒ CfnAddonProps
constructor
A new instance of CfnAddonProps.
- #to_jsii ⇒ Object
Constructor Details
#initialize(addon_name:, cluster_name:, addon_version: nil, configuration_values: nil, namespace_config: nil, pod_identity_associations: nil, preserve_on_delete: nil, resolve_conflicts: nil, service_account_role_arn: nil, tags: nil) ⇒ CfnAddonProps
Returns a new instance of CfnAddonProps.
19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 |
# File 'eks/cfn_addon_props.rb', line 19 def initialize(addon_name:, cluster_name:, addon_version: nil, configuration_values: nil, namespace_config: nil, pod_identity_associations: nil, preserve_on_delete: nil, resolve_conflicts: nil, service_account_role_arn: nil, tags: nil) @addon_name = addon_name Jsii::Type.check_type(@addon_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "addonName") @cluster_name = cluster_name Jsii::Type.check_type(@cluster_name, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "clusterName") @addon_version = addon_version Jsii::Type.check_type(@addon_version, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "addonVersion") unless @addon_version.nil? @configuration_values = configuration_values Jsii::Type.check_type(@configuration_values, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "configurationValues") unless @configuration_values.nil? @namespace_config = namespace_config.is_a?(Hash) ? ::AWSCDK::EKS::CfnAddon::NamespaceConfigProperty.new(**namespace_config.transform_keys(&:to_sym)) : namespace_config Jsii::Type.check_type(@namespace_config, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19la3MuQ2ZuQWRkb24uTmFtZXNwYWNlQ29uZmlnUHJvcGVydHkifV19fQ==")), "namespaceConfig") unless @namespace_config.nil? @pod_identity_associations = pod_identity_associations Jsii::Type.check_type(@pod_identity_associations, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsidW5pb24iOnsidHlwZXMiOlt7ImZxbiI6ImF3cy1jZGstbGliLklSZXNvbHZhYmxlIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5hd3NfZWtzLkNmbkFkZG9uLlBvZElkZW50aXR5QXNzb2NpYXRpb25Qcm9wZXJ0eSJ9XX19LCJraW5kIjoiYXJyYXkifX1dfX0=")), "podIdentityAssociations") unless @pod_identity_associations.nil? @preserve_on_delete = preserve_on_delete Jsii::Type.check_type(@preserve_on_delete, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoiYm9vbGVhbiJ9LHsiZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifV19fQ==")), "preserveOnDelete") unless @preserve_on_delete.nil? @resolve_conflicts = resolve_conflicts Jsii::Type.check_type(@resolve_conflicts, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "resolveConflicts") unless @resolve_conflicts.nil? @service_account_role_arn = service_account_role_arn Jsii::Type.check_type(@service_account_role_arn, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoic3RyaW5nIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5pbnRlcmZhY2VzLmF3c19pYW0uSVJvbGVSZWYifV19fQ==")), "serviceAccountRoleArn") unless @service_account_role_arn.nil? @tags = .is_a?(Array) ? .map { |jsii_v0| jsii_v0.is_a?(Hash) ? ::AWSCDK::CfnTag.new(**jsii_v0.transform_keys(&:to_sym)) : jsii_v0 } : Jsii::Type.check_type(@tags, JSON.parse(Base64.strict_decode64("eyJjb2xsZWN0aW9uIjp7ImVsZW1lbnR0eXBlIjp7ImZxbiI6ImF3cy1jZGstbGliLkNmblRhZyJ9LCJraW5kIjoiYXJyYXkifX0=")), "tags") unless @tags.nil? end |
Instance Attribute Details
#addon_name ⇒ String (readonly)
The name of the add-on.
46 47 48 |
# File 'eks/cfn_addon_props.rb', line 46 def addon_name @addon_name end |
#addon_version ⇒ String? (readonly)
The version of the add-on.
56 57 58 |
# File 'eks/cfn_addon_props.rb', line 56 def addon_version @addon_version end |
#cluster_name ⇒ String (readonly)
The name of your cluster.
51 52 53 |
# File 'eks/cfn_addon_props.rb', line 51 def cluster_name @cluster_name end |
#configuration_values ⇒ String? (readonly)
The configuration values that you provided.
61 62 63 |
# File 'eks/cfn_addon_props.rb', line 61 def configuration_values @configuration_values end |
#namespace_config ⇒ AWSCDK::IResolvable, ... (readonly)
The namespace configuration for the addon.
This specifies the Kubernetes namespace where the addon is installed.
68 69 70 |
# File 'eks/cfn_addon_props.rb', line 68 def namespace_config @namespace_config end |
#pod_identity_associations ⇒ AWSCDK::IResolvable, ... (readonly)
An array of EKS Pod Identity associations owned by the add-on.
Each association maps a role to a service account in a namespace in the cluster.
For more information, see Attach an IAM Role to an Amazon EKS add-on using EKS Pod Identity in the Amazon EKS User Guide .
77 78 79 |
# File 'eks/cfn_addon_props.rb', line 77 def pod_identity_associations @pod_identity_associations end |
#preserve_on_delete ⇒ Boolean, ... (readonly)
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.
84 85 86 |
# File 'eks/cfn_addon_props.rb', line 84 def preserve_on_delete @preserve_on_delete end |
#resolve_conflicts ⇒ String? (readonly)
How to resolve field value conflicts for an Amazon EKS add-on.
Conflicts are handled based on the value you choose:
- None – If the self-managed version of the add-on is installed on your cluster, Amazon EKS doesn't change the value. Creation of the add-on might fail.
- Overwrite – If the self-managed version of the add-on is installed on your cluster and the Amazon EKS default value is different than the existing value, Amazon EKS changes the value to the Amazon EKS default value.
- Preserve – This is similar to the NONE option. If the self-managed version of the add-on is installed on your cluster Amazon EKS doesn't change the add-on resource properties. Creation of the add-on might fail if conflicts are detected. This option works differently during the update operation. For more information, see
UpdateAddon.
If you don't currently have the self-managed version of the add-on installed on your cluster, the Amazon EKS add-on is installed. Amazon EKS sets all values to default values, regardless of the option that you specify.
97 98 99 |
# File 'eks/cfn_addon_props.rb', line 97 def resolve_conflicts @resolve_conflicts end |
#service_account_role_arn ⇒ String, ... (readonly)
The Amazon Resource Name (ARN) of an existing IAM role to bind to the add-on's service account.
The role must be assigned the IAM permissions required by the add-on. If you don't specify an existing IAM role, then the add-on uses the permissions assigned to the node IAM role. For more information, see Amazon EKS node IAM role in the Amazon EKS User Guide .
To specify an existing IAM role, you must have an IAM OpenID Connect (OIDC) provider created for your cluster. For more information, see Enabling IAM roles for service accounts on your cluster in the Amazon EKS User Guide .
106 107 108 |
# File 'eks/cfn_addon_props.rb', line 106 def service_account_role_arn @service_account_role_arn end |
#tags ⇒ Array<AWSCDK::CfnTag>? (readonly)
The metadata that you apply to the add-on to assist with categorization and organization.
Each tag consists of a key and an optional value, both of which you define. Add-on tags do not propagate to any other resources associated with the cluster.
113 114 115 |
# File 'eks/cfn_addon_props.rb', line 113 def @tags end |
Class Method Details
.jsii_properties ⇒ Object
115 116 117 118 119 120 121 122 123 124 125 126 127 128 |
# File 'eks/cfn_addon_props.rb', line 115 def self.jsii_properties { :addon_name => "addonName", :cluster_name => "clusterName", :addon_version => "addonVersion", :configuration_values => "configurationValues", :namespace_config => "namespaceConfig", :pod_identity_associations => "podIdentityAssociations", :preserve_on_delete => "preserveOnDelete", :resolve_conflicts => "resolveConflicts", :service_account_role_arn => "serviceAccountRoleArn", :tags => "tags", } end |
Instance Method Details
#to_jsii ⇒ Object
130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 |
# File 'eks/cfn_addon_props.rb', line 130 def to_jsii result = {} result.merge!({ "addonName" => @addon_name, "clusterName" => @cluster_name, "addonVersion" => @addon_version, "configurationValues" => @configuration_values, "namespaceConfig" => @namespace_config, "podIdentityAssociations" => @pod_identity_associations, "preserveOnDelete" => @preserve_on_delete, "resolveConflicts" => @resolve_conflicts, "serviceAccountRoleArn" => @service_account_role_arn, "tags" => @tags, }) result.compact end |