aws_sdk_eks/operation/create_addon/
_create_addon_input.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2#[allow(missing_docs)] // documentation missing in model
3#[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
5pub struct CreateAddonInput {
6    /// <p>The name of your cluster.</p>
7    pub cluster_name: ::std::option::Option<::std::string::String>,
8    /// <p>The name of the add-on. The name must match one of the names returned by <code>DescribeAddonVersions</code>.</p>
9    pub addon_name: ::std::option::Option<::std::string::String>,
10    /// <p>The version of the add-on. The version must match one of the versions returned by <a href="https://docs.aws.amazon.com/eks/latest/APIReference/API_DescribeAddonVersions.html"> <code>DescribeAddonVersions</code> </a>.</p>
11    pub addon_version: ::std::option::Option<::std::string::String>,
12    /// <p>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 <a href="https://docs.aws.amazon.com/eks/latest/userguide/create-node-role.html">Amazon EKS node IAM role</a> in the <i>Amazon EKS User Guide</i>.</p><note>
13    /// <p>To specify an existing IAM role, you must have an IAM OpenID Connect (OIDC) provider created for your cluster. For more information, see <a href="https://docs.aws.amazon.com/eks/latest/userguide/enable-iam-roles-for-service-accounts.html">Enabling IAM roles for service accounts on your cluster</a> in the <i>Amazon EKS User Guide</i>.</p>
14    /// </note>
15    pub service_account_role_arn: ::std::option::Option<::std::string::String>,
16    /// <p>How to resolve field value conflicts for an Amazon EKS add-on. Conflicts are handled based on the value you choose:</p>
17    /// <ul>
18    /// <li>
19    /// <p><b>None</b> – 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.</p></li>
20    /// <li>
21    /// <p><b>Overwrite</b> – 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.</p></li>
22    /// <li>
23    /// <p><b>Preserve</b> – 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 <a href="https://docs.aws.amazon.com/eks/latest/APIReference/API_UpdateAddon.html"> <code>UpdateAddon</code> </a>.</p></li>
24    /// </ul>
25    /// <p>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.</p>
26    pub resolve_conflicts: ::std::option::Option<crate::types::ResolveConflicts>,
27    /// <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request.</p>
28    pub client_request_token: ::std::option::Option<::std::string::String>,
29    /// <p>Metadata that assists with categorization and organization. Each tag consists of a key and an optional value. You define both. Tags don't propagate to any other cluster or Amazon Web Services resources.</p>
30    pub tags: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
31    /// <p>The set of configuration values for the add-on that's created. The values that you provide are validated against the schema returned by <code>DescribeAddonConfiguration</code>.</p>
32    pub configuration_values: ::std::option::Option<::std::string::String>,
33    /// <p>An array of EKS Pod Identity associations to be created. Each association maps a Kubernetes service account to an IAM role.</p>
34    /// <p>For more information, see <a href="https://docs.aws.amazon.com/eks/latest/userguide/add-ons-iam.html">Attach an IAM Role to an Amazon EKS add-on using EKS Pod Identity</a> in the <i>Amazon EKS User Guide</i>.</p>
35    pub pod_identity_associations: ::std::option::Option<::std::vec::Vec<crate::types::AddonPodIdentityAssociations>>,
36    /// <p>The namespace configuration for the addon. If specified, this will override the default namespace for the addon.</p>
37    pub namespace_config: ::std::option::Option<crate::types::AddonNamespaceConfigRequest>,
38}
39impl CreateAddonInput {
40    /// <p>The name of your cluster.</p>
41    pub fn cluster_name(&self) -> ::std::option::Option<&str> {
42        self.cluster_name.as_deref()
43    }
44    /// <p>The name of the add-on. The name must match one of the names returned by <code>DescribeAddonVersions</code>.</p>
45    pub fn addon_name(&self) -> ::std::option::Option<&str> {
46        self.addon_name.as_deref()
47    }
48    /// <p>The version of the add-on. The version must match one of the versions returned by <a href="https://docs.aws.amazon.com/eks/latest/APIReference/API_DescribeAddonVersions.html"> <code>DescribeAddonVersions</code> </a>.</p>
49    pub fn addon_version(&self) -> ::std::option::Option<&str> {
50        self.addon_version.as_deref()
51    }
52    /// <p>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 <a href="https://docs.aws.amazon.com/eks/latest/userguide/create-node-role.html">Amazon EKS node IAM role</a> in the <i>Amazon EKS User Guide</i>.</p><note>
53    /// <p>To specify an existing IAM role, you must have an IAM OpenID Connect (OIDC) provider created for your cluster. For more information, see <a href="https://docs.aws.amazon.com/eks/latest/userguide/enable-iam-roles-for-service-accounts.html">Enabling IAM roles for service accounts on your cluster</a> in the <i>Amazon EKS User Guide</i>.</p>
54    /// </note>
55    pub fn service_account_role_arn(&self) -> ::std::option::Option<&str> {
56        self.service_account_role_arn.as_deref()
57    }
58    /// <p>How to resolve field value conflicts for an Amazon EKS add-on. Conflicts are handled based on the value you choose:</p>
59    /// <ul>
60    /// <li>
61    /// <p><b>None</b> – 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.</p></li>
62    /// <li>
63    /// <p><b>Overwrite</b> – 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.</p></li>
64    /// <li>
65    /// <p><b>Preserve</b> – 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 <a href="https://docs.aws.amazon.com/eks/latest/APIReference/API_UpdateAddon.html"> <code>UpdateAddon</code> </a>.</p></li>
66    /// </ul>
67    /// <p>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.</p>
68    pub fn resolve_conflicts(&self) -> ::std::option::Option<&crate::types::ResolveConflicts> {
69        self.resolve_conflicts.as_ref()
70    }
71    /// <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request.</p>
72    pub fn client_request_token(&self) -> ::std::option::Option<&str> {
73        self.client_request_token.as_deref()
74    }
75    /// <p>Metadata that assists with categorization and organization. Each tag consists of a key and an optional value. You define both. Tags don't propagate to any other cluster or Amazon Web Services resources.</p>
76    pub fn tags(&self) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, ::std::string::String>> {
77        self.tags.as_ref()
78    }
79    /// <p>The set of configuration values for the add-on that's created. The values that you provide are validated against the schema returned by <code>DescribeAddonConfiguration</code>.</p>
80    pub fn configuration_values(&self) -> ::std::option::Option<&str> {
81        self.configuration_values.as_deref()
82    }
83    /// <p>An array of EKS Pod Identity associations to be created. Each association maps a Kubernetes service account to an IAM role.</p>
84    /// <p>For more information, see <a href="https://docs.aws.amazon.com/eks/latest/userguide/add-ons-iam.html">Attach an IAM Role to an Amazon EKS add-on using EKS Pod Identity</a> in the <i>Amazon EKS User Guide</i>.</p>
85    ///
86    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.pod_identity_associations.is_none()`.
87    pub fn pod_identity_associations(&self) -> &[crate::types::AddonPodIdentityAssociations] {
88        self.pod_identity_associations.as_deref().unwrap_or_default()
89    }
90    /// <p>The namespace configuration for the addon. If specified, this will override the default namespace for the addon.</p>
91    pub fn namespace_config(&self) -> ::std::option::Option<&crate::types::AddonNamespaceConfigRequest> {
92        self.namespace_config.as_ref()
93    }
94}
95impl CreateAddonInput {
96    /// Creates a new builder-style object to manufacture [`CreateAddonInput`](crate::operation::create_addon::CreateAddonInput).
97    pub fn builder() -> crate::operation::create_addon::builders::CreateAddonInputBuilder {
98        crate::operation::create_addon::builders::CreateAddonInputBuilder::default()
99    }
100}
101
102/// A builder for [`CreateAddonInput`](crate::operation::create_addon::CreateAddonInput).
103#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
104#[non_exhaustive]
105pub struct CreateAddonInputBuilder {
106    pub(crate) cluster_name: ::std::option::Option<::std::string::String>,
107    pub(crate) addon_name: ::std::option::Option<::std::string::String>,
108    pub(crate) addon_version: ::std::option::Option<::std::string::String>,
109    pub(crate) service_account_role_arn: ::std::option::Option<::std::string::String>,
110    pub(crate) resolve_conflicts: ::std::option::Option<crate::types::ResolveConflicts>,
111    pub(crate) client_request_token: ::std::option::Option<::std::string::String>,
112    pub(crate) tags: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
113    pub(crate) configuration_values: ::std::option::Option<::std::string::String>,
114    pub(crate) pod_identity_associations: ::std::option::Option<::std::vec::Vec<crate::types::AddonPodIdentityAssociations>>,
115    pub(crate) namespace_config: ::std::option::Option<crate::types::AddonNamespaceConfigRequest>,
116}
117impl CreateAddonInputBuilder {
118    /// <p>The name of your cluster.</p>
119    /// This field is required.
120    pub fn cluster_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
121        self.cluster_name = ::std::option::Option::Some(input.into());
122        self
123    }
124    /// <p>The name of your cluster.</p>
125    pub fn set_cluster_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
126        self.cluster_name = input;
127        self
128    }
129    /// <p>The name of your cluster.</p>
130    pub fn get_cluster_name(&self) -> &::std::option::Option<::std::string::String> {
131        &self.cluster_name
132    }
133    /// <p>The name of the add-on. The name must match one of the names returned by <code>DescribeAddonVersions</code>.</p>
134    /// This field is required.
135    pub fn addon_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
136        self.addon_name = ::std::option::Option::Some(input.into());
137        self
138    }
139    /// <p>The name of the add-on. The name must match one of the names returned by <code>DescribeAddonVersions</code>.</p>
140    pub fn set_addon_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
141        self.addon_name = input;
142        self
143    }
144    /// <p>The name of the add-on. The name must match one of the names returned by <code>DescribeAddonVersions</code>.</p>
145    pub fn get_addon_name(&self) -> &::std::option::Option<::std::string::String> {
146        &self.addon_name
147    }
148    /// <p>The version of the add-on. The version must match one of the versions returned by <a href="https://docs.aws.amazon.com/eks/latest/APIReference/API_DescribeAddonVersions.html"> <code>DescribeAddonVersions</code> </a>.</p>
149    pub fn addon_version(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
150        self.addon_version = ::std::option::Option::Some(input.into());
151        self
152    }
153    /// <p>The version of the add-on. The version must match one of the versions returned by <a href="https://docs.aws.amazon.com/eks/latest/APIReference/API_DescribeAddonVersions.html"> <code>DescribeAddonVersions</code> </a>.</p>
154    pub fn set_addon_version(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
155        self.addon_version = input;
156        self
157    }
158    /// <p>The version of the add-on. The version must match one of the versions returned by <a href="https://docs.aws.amazon.com/eks/latest/APIReference/API_DescribeAddonVersions.html"> <code>DescribeAddonVersions</code> </a>.</p>
159    pub fn get_addon_version(&self) -> &::std::option::Option<::std::string::String> {
160        &self.addon_version
161    }
162    /// <p>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 <a href="https://docs.aws.amazon.com/eks/latest/userguide/create-node-role.html">Amazon EKS node IAM role</a> in the <i>Amazon EKS User Guide</i>.</p><note>
163    /// <p>To specify an existing IAM role, you must have an IAM OpenID Connect (OIDC) provider created for your cluster. For more information, see <a href="https://docs.aws.amazon.com/eks/latest/userguide/enable-iam-roles-for-service-accounts.html">Enabling IAM roles for service accounts on your cluster</a> in the <i>Amazon EKS User Guide</i>.</p>
164    /// </note>
165    pub fn service_account_role_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
166        self.service_account_role_arn = ::std::option::Option::Some(input.into());
167        self
168    }
169    /// <p>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 <a href="https://docs.aws.amazon.com/eks/latest/userguide/create-node-role.html">Amazon EKS node IAM role</a> in the <i>Amazon EKS User Guide</i>.</p><note>
170    /// <p>To specify an existing IAM role, you must have an IAM OpenID Connect (OIDC) provider created for your cluster. For more information, see <a href="https://docs.aws.amazon.com/eks/latest/userguide/enable-iam-roles-for-service-accounts.html">Enabling IAM roles for service accounts on your cluster</a> in the <i>Amazon EKS User Guide</i>.</p>
171    /// </note>
172    pub fn set_service_account_role_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
173        self.service_account_role_arn = input;
174        self
175    }
176    /// <p>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 <a href="https://docs.aws.amazon.com/eks/latest/userguide/create-node-role.html">Amazon EKS node IAM role</a> in the <i>Amazon EKS User Guide</i>.</p><note>
177    /// <p>To specify an existing IAM role, you must have an IAM OpenID Connect (OIDC) provider created for your cluster. For more information, see <a href="https://docs.aws.amazon.com/eks/latest/userguide/enable-iam-roles-for-service-accounts.html">Enabling IAM roles for service accounts on your cluster</a> in the <i>Amazon EKS User Guide</i>.</p>
178    /// </note>
179    pub fn get_service_account_role_arn(&self) -> &::std::option::Option<::std::string::String> {
180        &self.service_account_role_arn
181    }
182    /// <p>How to resolve field value conflicts for an Amazon EKS add-on. Conflicts are handled based on the value you choose:</p>
183    /// <ul>
184    /// <li>
185    /// <p><b>None</b> – 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.</p></li>
186    /// <li>
187    /// <p><b>Overwrite</b> – 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.</p></li>
188    /// <li>
189    /// <p><b>Preserve</b> – 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 <a href="https://docs.aws.amazon.com/eks/latest/APIReference/API_UpdateAddon.html"> <code>UpdateAddon</code> </a>.</p></li>
190    /// </ul>
191    /// <p>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.</p>
192    pub fn resolve_conflicts(mut self, input: crate::types::ResolveConflicts) -> Self {
193        self.resolve_conflicts = ::std::option::Option::Some(input);
194        self
195    }
196    /// <p>How to resolve field value conflicts for an Amazon EKS add-on. Conflicts are handled based on the value you choose:</p>
197    /// <ul>
198    /// <li>
199    /// <p><b>None</b> – 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.</p></li>
200    /// <li>
201    /// <p><b>Overwrite</b> – 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.</p></li>
202    /// <li>
203    /// <p><b>Preserve</b> – 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 <a href="https://docs.aws.amazon.com/eks/latest/APIReference/API_UpdateAddon.html"> <code>UpdateAddon</code> </a>.</p></li>
204    /// </ul>
205    /// <p>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.</p>
206    pub fn set_resolve_conflicts(mut self, input: ::std::option::Option<crate::types::ResolveConflicts>) -> Self {
207        self.resolve_conflicts = input;
208        self
209    }
210    /// <p>How to resolve field value conflicts for an Amazon EKS add-on. Conflicts are handled based on the value you choose:</p>
211    /// <ul>
212    /// <li>
213    /// <p><b>None</b> – 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.</p></li>
214    /// <li>
215    /// <p><b>Overwrite</b> – 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.</p></li>
216    /// <li>
217    /// <p><b>Preserve</b> – 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 <a href="https://docs.aws.amazon.com/eks/latest/APIReference/API_UpdateAddon.html"> <code>UpdateAddon</code> </a>.</p></li>
218    /// </ul>
219    /// <p>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.</p>
220    pub fn get_resolve_conflicts(&self) -> &::std::option::Option<crate::types::ResolveConflicts> {
221        &self.resolve_conflicts
222    }
223    /// <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request.</p>
224    pub fn client_request_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
225        self.client_request_token = ::std::option::Option::Some(input.into());
226        self
227    }
228    /// <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request.</p>
229    pub fn set_client_request_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
230        self.client_request_token = input;
231        self
232    }
233    /// <p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request.</p>
234    pub fn get_client_request_token(&self) -> &::std::option::Option<::std::string::String> {
235        &self.client_request_token
236    }
237    /// Adds a key-value pair to `tags`.
238    ///
239    /// To override the contents of this collection use [`set_tags`](Self::set_tags).
240    ///
241    /// <p>Metadata that assists with categorization and organization. Each tag consists of a key and an optional value. You define both. Tags don't propagate to any other cluster or Amazon Web Services resources.</p>
242    pub fn tags(mut self, k: impl ::std::convert::Into<::std::string::String>, v: impl ::std::convert::Into<::std::string::String>) -> Self {
243        let mut hash_map = self.tags.unwrap_or_default();
244        hash_map.insert(k.into(), v.into());
245        self.tags = ::std::option::Option::Some(hash_map);
246        self
247    }
248    /// <p>Metadata that assists with categorization and organization. Each tag consists of a key and an optional value. You define both. Tags don't propagate to any other cluster or Amazon Web Services resources.</p>
249    pub fn set_tags(mut self, input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>) -> Self {
250        self.tags = input;
251        self
252    }
253    /// <p>Metadata that assists with categorization and organization. Each tag consists of a key and an optional value. You define both. Tags don't propagate to any other cluster or Amazon Web Services resources.</p>
254    pub fn get_tags(&self) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>> {
255        &self.tags
256    }
257    /// <p>The set of configuration values for the add-on that's created. The values that you provide are validated against the schema returned by <code>DescribeAddonConfiguration</code>.</p>
258    pub fn configuration_values(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
259        self.configuration_values = ::std::option::Option::Some(input.into());
260        self
261    }
262    /// <p>The set of configuration values for the add-on that's created. The values that you provide are validated against the schema returned by <code>DescribeAddonConfiguration</code>.</p>
263    pub fn set_configuration_values(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
264        self.configuration_values = input;
265        self
266    }
267    /// <p>The set of configuration values for the add-on that's created. The values that you provide are validated against the schema returned by <code>DescribeAddonConfiguration</code>.</p>
268    pub fn get_configuration_values(&self) -> &::std::option::Option<::std::string::String> {
269        &self.configuration_values
270    }
271    /// Appends an item to `pod_identity_associations`.
272    ///
273    /// To override the contents of this collection use [`set_pod_identity_associations`](Self::set_pod_identity_associations).
274    ///
275    /// <p>An array of EKS Pod Identity associations to be created. Each association maps a Kubernetes service account to an IAM role.</p>
276    /// <p>For more information, see <a href="https://docs.aws.amazon.com/eks/latest/userguide/add-ons-iam.html">Attach an IAM Role to an Amazon EKS add-on using EKS Pod Identity</a> in the <i>Amazon EKS User Guide</i>.</p>
277    pub fn pod_identity_associations(mut self, input: crate::types::AddonPodIdentityAssociations) -> Self {
278        let mut v = self.pod_identity_associations.unwrap_or_default();
279        v.push(input);
280        self.pod_identity_associations = ::std::option::Option::Some(v);
281        self
282    }
283    /// <p>An array of EKS Pod Identity associations to be created. Each association maps a Kubernetes service account to an IAM role.</p>
284    /// <p>For more information, see <a href="https://docs.aws.amazon.com/eks/latest/userguide/add-ons-iam.html">Attach an IAM Role to an Amazon EKS add-on using EKS Pod Identity</a> in the <i>Amazon EKS User Guide</i>.</p>
285    pub fn set_pod_identity_associations(
286        mut self,
287        input: ::std::option::Option<::std::vec::Vec<crate::types::AddonPodIdentityAssociations>>,
288    ) -> Self {
289        self.pod_identity_associations = input;
290        self
291    }
292    /// <p>An array of EKS Pod Identity associations to be created. Each association maps a Kubernetes service account to an IAM role.</p>
293    /// <p>For more information, see <a href="https://docs.aws.amazon.com/eks/latest/userguide/add-ons-iam.html">Attach an IAM Role to an Amazon EKS add-on using EKS Pod Identity</a> in the <i>Amazon EKS User Guide</i>.</p>
294    pub fn get_pod_identity_associations(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::AddonPodIdentityAssociations>> {
295        &self.pod_identity_associations
296    }
297    /// <p>The namespace configuration for the addon. If specified, this will override the default namespace for the addon.</p>
298    pub fn namespace_config(mut self, input: crate::types::AddonNamespaceConfigRequest) -> Self {
299        self.namespace_config = ::std::option::Option::Some(input);
300        self
301    }
302    /// <p>The namespace configuration for the addon. If specified, this will override the default namespace for the addon.</p>
303    pub fn set_namespace_config(mut self, input: ::std::option::Option<crate::types::AddonNamespaceConfigRequest>) -> Self {
304        self.namespace_config = input;
305        self
306    }
307    /// <p>The namespace configuration for the addon. If specified, this will override the default namespace for the addon.</p>
308    pub fn get_namespace_config(&self) -> &::std::option::Option<crate::types::AddonNamespaceConfigRequest> {
309        &self.namespace_config
310    }
311    /// Consumes the builder and constructs a [`CreateAddonInput`](crate::operation::create_addon::CreateAddonInput).
312    pub fn build(self) -> ::std::result::Result<crate::operation::create_addon::CreateAddonInput, ::aws_smithy_types::error::operation::BuildError> {
313        ::std::result::Result::Ok(crate::operation::create_addon::CreateAddonInput {
314            cluster_name: self.cluster_name,
315            addon_name: self.addon_name,
316            addon_version: self.addon_version,
317            service_account_role_arn: self.service_account_role_arn,
318            resolve_conflicts: self.resolve_conflicts,
319            client_request_token: self.client_request_token,
320            tags: self.tags,
321            configuration_values: self.configuration_values,
322            pod_identity_associations: self.pod_identity_associations,
323            namespace_config: self.namespace_config,
324        })
325    }
326}