Class: AWS.EKS
- Inherits:
-
AWS.Service
- Object
- AWS.Service
- AWS.EKS
- Identifier:
- eks
- API Version:
- 2017-11-01
- Defined in:
- (unknown)
Overview
Constructs a service interface object. Each API operation is exposed as a function on service.
Service Description
Amazon Elastic Container Service for Kubernetes (Amazon EKS) is a managed service that makes it easy for you to run Kubernetes on AWS without needing to stand up or maintain your own Kubernetes control plane. Kubernetes is an open-source system for automating the deployment, scaling, and management of containerized applications.
Amazon EKS runs up-to-date versions of the open-source Kubernetes software, so you can use all the existing plugins and tooling from the Kubernetes community. Applications running on Amazon EKS are fully compatible with applications running on any standard Kubernetes environment, whether running in on-premises data centers or public clouds. This means that you can easily migrate any standard Kubernetes application to Amazon EKS without any code modification required.
Sending a Request Using EKS
var eks = new AWS.EKS();
eks.createCluster(params, function (err, data) {
if (err) console.log(err, err.stack); // an error occurred
else console.log(data); // successful response
});
Locking the API Version
In order to ensure that the EKS object uses this specific API, you can
construct the object by passing the apiVersion
option to the constructor:
var eks = new AWS.EKS({apiVersion: '2017-11-01'});
You can also set the API version globally in AWS.config.apiVersions
using
the eks service identifier:
AWS.config.apiVersions = {
eks: '2017-11-01',
// other service API versions
};
var eks = new AWS.EKS();
Waiter Resource States
This service supports a list of resource states that can be polled using the waitFor() method. The resource states are:
Constructor Summary
-
new AWS.EKS(options = {}) ⇒ Object
constructor
Constructs a service object.
Property Summary
-
endpoint ⇒ AWS.Endpoint
readwrite
An Endpoint object representing the endpoint URL for service requests.
Properties inherited from AWS.Service
Method Summary
-
createCluster(params = {}, callback) ⇒ AWS.Request
Creates an Amazon EKS control plane.
-
deleteCluster(params = {}, callback) ⇒ AWS.Request
Deletes the Amazon EKS cluster control plane.
-
describeCluster(params = {}, callback) ⇒ AWS.Request
Returns descriptive information about an Amazon EKS cluster.
-
describeUpdate(params = {}, callback) ⇒ AWS.Request
Returns descriptive information about an update against your Amazon EKS cluster.
-
listClusters(params = {}, callback) ⇒ AWS.Request
Lists the Amazon EKS clusters in your AWS account in the specified Region.
-
listUpdates(params = {}, callback) ⇒ AWS.Request
Lists the updates associated with an Amazon EKS cluster in your AWS account, in the specified Region.
-
updateClusterConfig(params = {}, callback) ⇒ AWS.Request
Updates an Amazon EKS cluster configuration.
-
updateClusterVersion(params = {}, callback) ⇒ AWS.Request
Updates an Amazon EKS cluster to the specified Kubernetes version.
-
waitFor(state, params = {}, callback) ⇒ AWS.Request
Waits for a given EKS resource.
Methods inherited from AWS.Service
makeRequest, makeUnauthenticatedRequest, setupRequestListeners, defineService
Constructor Details
Property Details
Method Details
createCluster(params = {}, callback) ⇒ AWS.Request
Creates an Amazon EKS control plane.
The Amazon EKS control plane consists of control plane instances that run the Kubernetes software, like etcd
and the API server. The control plane runs in an account managed by AWS, and the Kubernetes API is exposed via the Amazon EKS API server endpoint. Each Amazon EKS cluster control plane is single-tenant and unique, and runs on its own set of Amazon EC2 instances.
The cluster control plane is provisioned across multiple Availability Zones and fronted by an Elastic Load Balancing Network Load Balancer. Amazon EKS also provisions elastic network interfaces in your VPC subnets to provide connectivity from the control plane instances to the worker nodes (for example, to support kubectl exec
, logs
, and proxy
data flows).
Amazon EKS worker nodes run in your AWS account and connect to your cluster's control plane via the Kubernetes API server endpoint and a certificate file that is created for your cluster.
You can use the endpointPublicAccess
and endpointPrivateAccess
parameters to enable or disable public and private access to your cluster's Kubernetes API server endpoint. By default, public access is enabled and private access is disabled. For more information, see Amazon EKS Cluster Endpoint Access Control in the Amazon EKS User Guide .
You can use the logging
parameter to enable or disable exporting the Kubernetes control plane logs for your cluster to CloudWatch Logs. By default, cluster control plane logs are not exported to CloudWatch Logs. For more information, see Amazon EKS Cluster Control Plane Logs in the Amazon EKS User Guide .
Cluster creation typically takes between 10 and 15 minutes. After you create an Amazon EKS cluster, you must configure your Kubernetes tooling to communicate with the API server and launch worker nodes into your cluster. For more information, see Managing Cluster Authentication and Launching Amazon EKS Worker Nodes in the Amazon EKS User Guide.
deleteCluster(params = {}, callback) ⇒ AWS.Request
Deletes the Amazon EKS cluster control plane.
describeCluster(params = {}, callback) ⇒ AWS.Request
Returns descriptive information about an Amazon EKS cluster.
The API server endpoint and certificate authority data returned by this operation are required for kubelet
and kubectl
to communicate with your Kubernetes API server. For more information, see Create a kubeconfig for Amazon EKS.
ACTIVE
state. describeUpdate(params = {}, callback) ⇒ AWS.Request
Returns descriptive information about an update against your Amazon EKS cluster.
When the status of the update is Succeeded
, the update is complete. If an update fails, the status is Failed
, and an error detail explains the reason for the failure.
listClusters(params = {}, callback) ⇒ AWS.Request
Lists the Amazon EKS clusters in your AWS account in the specified Region.
listUpdates(params = {}, callback) ⇒ AWS.Request
Lists the updates associated with an Amazon EKS cluster in your AWS account, in the specified Region.
updateClusterConfig(params = {}, callback) ⇒ AWS.Request
Updates an Amazon EKS cluster configuration. Your cluster continues to function during the update. The response output includes an update ID that you can use to track the status of your cluster update with the DescribeUpdate API operation.
You can use this API operation to enable or disable public and private access to your cluster's Kubernetes API server endpoint. By default, public access is enabled and private access is disabled. For more information, see Amazon EKS Cluster Endpoint Access Control in the Amazon EKS User Guide .
You can also use this API operation to enable or disable exporting the Kubernetes control plane logs for your cluster to CloudWatch Logs. By default, cluster control plane logs are not exported to CloudWatch Logs. For more information, see Amazon EKS Cluster Control Plane Logs in the Amazon EKS User Guide .
Cluster updates are asynchronous, and they should finish within a few minutes. During an update, the cluster status moves to UPDATING
(this status transition is eventually consistent). When the update is complete (either Failed
or Successful
), the cluster status moves to Active
.
updateClusterVersion(params = {}, callback) ⇒ AWS.Request
Updates an Amazon EKS cluster to the specified Kubernetes version. Your cluster continues to function during the update. The response output includes an update ID that you can use to track the status of your cluster update with the DescribeUpdate API operation.
Cluster updates are asynchronous, and they should finish within a few minutes. During an update, the cluster status moves to UPDATING
(this status transition is eventually consistent). When the update is complete (either Failed
or Successful
), the cluster status moves to Active
.
waitFor(state, params = {}, callback) ⇒ AWS.Request
Waits for a given EKS resource. The final callback or 'complete' event will be fired only when the resource is either in its final state or the waiter has timed out and stopped polling for the final state.
Waiter Resource Details
eks.waitFor('clusterActive', params = {}, [callback]) ⇒ AWS.Request
Waits for the clusterActive
state by periodically calling the underlying
EKS.describeCluster() operation every 30 seconds
(at most 40 times).
eks.waitFor('clusterDeleted', params = {}, [callback]) ⇒ AWS.Request
Waits for the clusterDeleted
state by periodically calling the underlying
EKS.describeCluster() operation every 30 seconds
(at most 40 times).