Terraform Aws Eks Ecommerce screenshot

Terraform Aws Eks Ecommerce

Author Avatar Theme by Devgurusio
Updated: 9 Sep 2022
7 Stars

AWS Elastic Kubernetes Service starter kit to bootstrap an e-commerce site based on microservices

Categories

Overview

The Elastic Kubernetes Service (EKS) is a terraform module that allows for the easy bootstrap of an EKS Cluster using Terraform. It provides various features such as logging using Amazon Cloudwatch, firewall security measures, IAM accounts for service accounts, VPC native cluster, cluster autoscaler, IAM roles, and more. The module also enables updatable nodes through AWS autoscaling instance refreshes and utilizes containerd as a runtime.

Features

  • Logging using Amazon Cloudwatch: Enables logging of EKS cluster activities using Amazon Cloudwatch.
  • Firewall security measures: Implements firewall security measures to allow only required control-plane to nodes communication.
  • IAM accounts for service accounts: Provides IAM accounts for service accounts in EKS cluster.
  • VPC native cluster: Enables VPC native cluster functionality.
  • Cluster autoscaler: Implements the cluster autoscaler feature for automatic scaling of EKS cluster.
  • IAM Roles and Helm release installed: Installs IAM roles and Helm release in the EKS cluster.
  • Metrics server configured: Configures metrics server for monitoring EKS cluster.
  • Updatable nodes through AWS autoscaling instance refreshes: Enables updating of nodes through AWS autoscaling instance refreshes.
  • Non-default SA for nodes: Uses a non-default SA (Service Account) for nodes.
  • Usage of containerd as runtime: Configurable option to use containerd as the runtime instead of the default runtime.
  • aws-auth management: Provides management of aws-auth for EKS cluster.

Installation

To install the EKS module, follow these steps:

  1. Make sure you have Terraform version 1.0 or higher installed.

  2. The module requires the kubectl client to be installed on your local machine.

  3. Add the required providers to your Terraform configuration:

    • local ~> 2.1.0
    • aws ~> 3.73.0
    • kubernetes ~> 2.5.1
    • null >= 3.0
    • helm 2.4.0
  4. Set the input variables in your Terraform configuration:

    • environment: The environment where the cluster will be deployed. If not provided, the default value is “devgurus-dev”.
    • kubernetes_version: The Kubernetes version that the module will try to bootstrap. If not provided, the default value is “1.21”.
    • self_managed_node_groups: An object representing the node groups to be created.
    • vpc_cidr: The CIDR for the VPC to be created.
  5. Run terraform init to initialize the Terraform configuration.

  6. Run terraform apply to apply the changes and create the EKS Cluster.

Summary

The Elastic Kubernetes Service (EKS) module is a convenient tool for bootstrapping an EKS Cluster using Terraform. It provides essential features such as logging, security measures, IAM accounts, VPC native cluster, autoscaling, and more. By following the installation guide, users can quickly set up an EKS Cluster with customizable options and configurations.