aws_sdk_eks/client/
create_capability.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2impl super::Client {
3    /// Constructs a fluent builder for the [`CreateCapability`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder) operation.
4    ///
5    /// - The fluent builder is configurable:
6    ///   - [`capability_name(impl Into<String>)`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::capability_name) / [`set_capability_name(Option<String>)`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::set_capability_name):<br>required: **true**<br><p>A unique name for the capability. The name must be unique within your cluster and can contain alphanumeric characters, hyphens, and underscores.</p><br>
7    ///   - [`cluster_name(impl Into<String>)`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::cluster_name) / [`set_cluster_name(Option<String>)`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::set_cluster_name):<br>required: **true**<br><p>The name of the Amazon EKS cluster where you want to create the capability.</p><br>
8    ///   - [`client_request_token(impl Into<String>)`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::client_request_token) / [`set_client_request_token(Option<String>)`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::set_client_request_token):<br>required: **false**<br><p>A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. This token is valid for 24 hours after creation. If you retry a request with the same client request token and the same parameters after the original request has completed successfully, the result of the original request is returned.</p><br>
9    ///   - [`r#type(CapabilityType)`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::type) / [`set_type(Option<CapabilityType>)`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::set_type):<br>required: **true**<br><p>The type of capability to create. Valid values are:</p> <ul>  <li>   <p><code>ACK</code> – Amazon Web Services Controllers for Kubernetes (ACK), which lets you manage resources directly from Kubernetes.</p></li>  <li>   <p><code>ARGOCD</code> – Argo CD for GitOps-based continuous delivery.</p></li>  <li>   <p><code>KRO</code> – Kube Resource Orchestrator (KRO) for composing and managing custom Kubernetes resources.</p></li> </ul><br>
10    ///   - [`role_arn(impl Into<String>)`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::role_arn) / [`set_role_arn(Option<String>)`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::set_role_arn):<br>required: **true**<br><p>The Amazon Resource Name (ARN) of the IAM role that the capability uses to interact with Amazon Web Services services. This role must have a trust policy that allows the EKS service principal to assume it, and it must have the necessary permissions for the capability type you're creating.</p> <p>For ACK capabilities, the role needs permissions to manage the resources you want to control through Kubernetes. For Argo CD capabilities, the role needs permissions to access Git repositories and Secrets Manager. For KRO capabilities, the role needs permissions based on the resources you'll be orchestrating.</p><br>
11    ///   - [`configuration(CapabilityConfigurationRequest)`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::configuration) / [`set_configuration(Option<CapabilityConfigurationRequest>)`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::set_configuration):<br>required: **false**<br><p>The configuration settings for the capability. The structure of this object varies depending on the capability type. For Argo CD capabilities, you can configure IAM Identity CenterIAM; Identity Center integration, RBAC role mappings, and network access settings.</p><br>
12    ///   - [`tags(impl Into<String>, impl Into<String>)`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::tags) / [`set_tags(Option<HashMap::<String, String>>)`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::set_tags):<br>required: **false**<br><p>The metadata that you apply to a resource to help you categorize and organize them. Each tag consists of a key and an optional value. You define them.</p> <p>The following basic restrictions apply to tags:</p> <ul>  <li>   <p>Maximum number of tags per resource – 50</p></li>  <li>   <p>For each resource, each tag key must be unique, and each tag key can have only one value.</p></li>  <li>   <p>Maximum key length – 128 Unicode characters in UTF-8</p></li>  <li>   <p>Maximum value length – 256 Unicode characters in UTF-8</p></li>  <li>   <p>If your tagging schema is used across multiple services and resources, remember that other services may have restrictions on allowed characters. Generally allowed characters are: letters, numbers, and spaces representable in UTF-8, and the following characters: + - = . _ : / @.</p></li>  <li>   <p>Tag keys and values are case-sensitive.</p></li>  <li>   <p>Do not use <code>aws:</code>, <code>AWS:</code>, or any upper or lowercase combination of such as a prefix for either keys or values as it is reserved for Amazon Web Services use. You cannot edit or delete tag keys or values with this prefix. Tags with this prefix do not count against your tags per resource limit.</p></li> </ul><br>
13    ///   - [`delete_propagation_policy(CapabilityDeletePropagationPolicy)`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::delete_propagation_policy) / [`set_delete_propagation_policy(Option<CapabilityDeletePropagationPolicy>)`](crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::set_delete_propagation_policy):<br>required: **true**<br><p>Specifies how Kubernetes resources managed by the capability should be handled when the capability is deleted. Currently, the only supported value is <code>RETAIN</code> which retains all Kubernetes resources managed by the capability when the capability is deleted.</p> <p>Because resources are retained, all Kubernetes resources created by the capability should be deleted from the cluster before deleting the capability itself. After the capability is deleted, these resources become difficult to manage because the controller is no longer available.</p><br>
14    /// - On success, responds with [`CreateCapabilityOutput`](crate::operation::create_capability::CreateCapabilityOutput) with field(s):
15    ///   - [`capability(Option<Capability>)`](crate::operation::create_capability::CreateCapabilityOutput::capability): <p>An object containing information about the newly created capability, including its name, ARN, status, and configuration.</p>
16    /// - On failure, responds with [`SdkError<CreateCapabilityError>`](crate::operation::create_capability::CreateCapabilityError)
17    pub fn create_capability(&self) -> crate::operation::create_capability::builders::CreateCapabilityFluentBuilder {
18        crate::operation::create_capability::builders::CreateCapabilityFluentBuilder::new(self.handle.clone())
19    }
20}