Interface KubectlProviderOptions
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Subinterfaces:
KubectlProviderProps
- All Known Implementing Classes:
KubectlProviderOptions.Jsii$Proxy,KubectlProviderProps.Jsii$Proxy
kubectl and helm against the cluster.
Example:
import software.amazon.awscdk.cdk.lambdalayer.kubectl.v34.KubectlV34Layer;
Cluster cluster = Cluster.Builder.create(this, "hello-eks")
.version(KubernetesVersion.V1_34)
.kubectlProviderOptions(KubectlProviderOptions.builder()
.kubectlLayer(new KubectlV34Layer(this, "kubectl"))
.environment(Map.of(
"http_proxy", "http://proxy.myproxy.com"))
.build())
.build();
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder forKubectlProviderOptionsstatic final classAn implementation forKubectlProviderOptions -
Method Summary
Modifier and TypeMethodDescriptionbuilder()default ILayerVersionAn AWS Lambda layer that contains theawsCLI.Custom environment variables when runningkubectlagainst this cluster.An AWS Lambda layer that includeskubectlandhelm.default SizeThe amount of memory allocated to the kubectl provider's lambda function.Subnets to host thekubectlcompute resources.default RemovalPolicyThe removal policy applied to the custom resource that provides kubectl.default IRolegetRole()An IAM role that can perform kubectl operations against this cluster.default ISecurityGroupA security group to use forkubectlexecution.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getKubectlLayer
An AWS Lambda layer that includeskubectlandhelm. -
getAwscliLayer
An AWS Lambda layer that contains theawsCLI.Default: - If not defined, a default layer will be used containing the AWS CLI 2.x.
-
getEnvironment
Custom environment variables when runningkubectlagainst this cluster.Default: - No custom environment variables
-
getMemory
The amount of memory allocated to the kubectl provider's lambda function.Default: - 1024
-
getPrivateSubnets
Subnets to host thekubectlcompute resources.If not specified, the k8s endpoint is expected to be accessible publicly.
Default: - the k8s is accessible publicly
-
getRemovalPolicy
The removal policy applied to the custom resource that provides kubectl.The removal policy controls what happens to the resource if it stops being managed by CloudFormation. This can happen in one of three situations:
- The resource is removed from the template, so CloudFormation stops managing it
- A change to the resource is made that requires it to be replaced, so CloudFormation stops managing it
- The stack is deleted, so CloudFormation stops managing all resources in it
Default: RemovalPolicy.DESTROY
-
getRole
An IAM role that can perform kubectl operations against this cluster.The role should be mapped to the
system:mastersKubernetes 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
A security group to use forkubectlexecution.Default: - If not specified, the k8s endpoint is expected to be accessible publicly.
-
builder
- Returns:
- a
KubectlProviderOptions.BuilderofKubectlProviderOptions
-