Interface KubectlProviderOptions

All Superinterfaces:
software.amazon.jsii.JsiiSerializable
All Known Subinterfaces:
KubectlProviderProps
All Known Implementing Classes:
KubectlProviderOptions.Jsii$Proxy, KubectlProviderProps.Jsii$Proxy

@Generated(value="jsii-pacmak/1.112.0 (build de1bc80)", date="2025-07-16T11:43:25.306Z") @Stability(Experimental) public interface KubectlProviderOptions extends software.amazon.jsii.JsiiSerializable
Example:

 import software.amazon.awscdk.cdk.lambdalayer.kubectl.v32.KubectlV32Layer;
 Cluster cluster = Cluster.Builder.create(this, "hello-eks")
         .version(KubernetesVersion.V1_32)
         .kubectlProviderOptions(KubectlProviderOptions.builder()
                 .kubectlLayer(new KubectlV32Layer(this, "kubectl"))
                 .environment(Map.of(
                         "http_proxy", "http://proxy.myproxy.com"))
                 .build())
         .build();
 
  • Method Details

    • getKubectlLayer

      @Stability(Experimental) @NotNull ILayerVersion getKubectlLayer()
      (experimental) An AWS Lambda layer that includes kubectl and helm.
    • getAwscliLayer

      @Stability(Experimental) @Nullable default ILayerVersion getAwscliLayer()
      (experimental) An AWS Lambda layer that contains the aws CLI.

      If not defined, a default layer will be used containing the AWS CLI 2.x.

    • getEnvironment

      @Stability(Experimental) @Nullable default Map<String,String> getEnvironment()
      (experimental) Custom environment variables when running kubectl against this cluster.
    • getMemory

      @Stability(Experimental) @Nullable default Size getMemory()
      (experimental) The amount of memory allocated to the kubectl provider's lambda function.
    • getPrivateSubnets

      @Stability(Experimental) @Nullable default List<ISubnet> getPrivateSubnets()
      (experimental) Subnets to host the kubectl compute resources.

      If not specified, the k8s endpoint is expected to be accessible publicly.

    • getRole

      @Stability(Experimental) @Nullable default IRole getRole()
      (experimental) An IAM role that can perform kubectl operations against this cluster.

      The role should be mapped to the system:masters Kubernetes RBAC role.

      This role is directly passed to the lambda handler that sends Kube Ctl commands to the cluster.

      Default: - if not specified, the default role created by a lambda function will be used.

    • getSecurityGroup

      @Stability(Experimental) @Nullable default ISecurityGroup getSecurityGroup()
      (experimental) A security group to use for kubectl execution.

      Default: - If not specified, the k8s endpoint is expected to be accessible publicly.

    • builder

      @Stability(Experimental) static KubectlProviderOptions.Builder builder()
      Returns:
      a KubectlProviderOptions.Builder of KubectlProviderOptions