Friday, 10 January 2020
Creating an EKS Cluster in AWS Using eksctl
In this article, we will create an EKS Cluster in AWS using [eksctl](https://github.com/weaveworks/eksctl).
eksctl is a simple CLI tool for creating clusters on EKS - Amazon's new managed Kubernetes service for EC2. It is written in Go, and uses CloudFormation.
This is the general architecture. This article only focuses on EKS part.

To install eksctl, you can use [homebrew](https://brew.sh/) if you are a macOS user:
```bash
brew tap weaveworks/tap
brew install weaveworks/tap/eksctl
```
or use [chocolatey](https://chocolatey.org/) if you are a Windows user:
```bash
chocolatey install eksctl
```
Before creating a cluster, make sure you have setup your aws credentials. To do that, you can run ``aws configure`` to perform your setup. The region for this demostration is ``us-east-1``.
After the configuration setup, you can run the below command to verify
```bash
aws sts get-caller-identity
```
To create a EKS cluster, you can simply use
```bash
eksctl create cluster
```
or with some parameters
```bash
eksctl create cluster --region=us-east-1 --node-type=t2.medium
```
If you don't specify parameters, the default parameters will be used:
```
exciting auto-generated name, e.g. "fabulous-mushroom-1527688624"
2x m5.large nodes (this instance type suits most common use-cases, and is good value for money)
use official AWS EKS AMI
us-west-2 region
dedicated VPC (check your quotas)
using static AMI resolver
```
The process may take up to 15 minutes.

Once it is ready, run the following command to verify
```bash
kubectl get nodes
```
```
NAME STATUS ROLES AGE VERSION
ip-192-168-10-12.ec2.internal Ready 2m6s v1.14.7-eks-1861c5
ip-192-168-41-124.ec2.internal Ready 2m5s v1.14.7-eks-1861c5
```
If you go to AWS Console and direct to EKS page, you can see there are three clusters created by ``eksctl``. Since we do not specify the name, so the cluster name is generated randomly.

For the eksctl documentation, please check out [here](https://eksctl.io/).
Subscribe to:
Post Comments (Atom)
A Fun Problem - Math
# Problem Statement JATC's math teacher always gives the class some interesting math problems so that they don't get bored. Today t...
-
SHA stands for Secure Hashing Algorithm and 2 is just a version number. SHA-2 revises the construction and the big-length of the signature f...
-
Contest Link: [https://www.e-olymp.com/en/contests/19775](https://www.e-olymp.com/en/contests/19775) Full Solution: [https://github.com/...
No comments:
Post a Comment