Skip to content

Latest commit

 

History

History
78 lines (69 loc) · 2.86 KB

README.md

File metadata and controls

78 lines (69 loc) · 2.86 KB

IMEKS

Boilerplate for Kubernetes Infrastructure As Code in AWS using Terraform (Updated at 2023-11-13)

image

Get Started

To build infrastructure, you need the following tools:

  • AWS CLI
  • Terraform CLI
  • kubectl
$ terraform init
$ terraform plan
$ terraform apply --auto-approve

kubectl CLI

$ aws eks --region <REGION> update-kubeconfig --name <CLUSTER_NAME>

Grafana Dashboard

If you select ClusterIP as service.type, you can connect through port-forwarding as follows.

$ kubectl port-forward -n grafana deploy/grafana 8081:3000

If you select LoadBalancer, you will be able to directly access the Endpoint of the LoadBalancer.

Structure Summary

  • Kubernetes 1.28+ on EKS
  • 2AZ, Public/Private/Intra Subnets
  • 2 Managed Nodegroups(Frontend, Backend)
  • Cluster AutoScaling with Karpenter
    • AWS Node Termination Handler
  • Ingress Controller with AWS Load Balancer
  • EFK Log Pipeline
    • Fleunt-bit
    • AWS Opensearch Service
    • Opensearch DashBoard (Kibana Alternative)
  • Cluster Montioring
    • Prometheus
    • Grafana
    • K8s Metric Server
  • Cert Manager, Etc.

Directories

<IMEKS>
├── LICENSE
├── README.md
├── assets
│   ├── sample/
│   └── terraform_backend/
└── src/
    └─ helm_values/
  • src/: Infrastructrue as code.
  • assets/sample/: Sample services to run on the cluster.
  • assets/terraform_backend: Backend for managing Terraform State.

Terraform Modules

Helm Release