https://github.com/iml1111/imeks
Boilerplate for Kubernetes Infrastructure As Code in AWS using Terraform
https://github.com/iml1111/imeks
aws efk eks grafana iac karpenter kubernetes prometheus terraform
Last synced: 6 months ago
JSON representation
Boilerplate for Kubernetes Infrastructure As Code in AWS using Terraform
- Host: GitHub
- URL: https://github.com/iml1111/imeks
- Owner: iml1111
- License: mit
- Created: 2023-11-07T08:29:47.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2023-11-19T12:11:44.000Z (almost 2 years ago)
- Last Synced: 2025-04-24T00:03:29.019Z (6 months ago)
- Topics: aws, efk, eks, grafana, iac, karpenter, kubernetes, prometheus, terraform
- Language: HCL
- Homepage:
- Size: 22.5 KB
- Stars: 6
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# IMEKS
Boilerplate for Kubernetes Infrastructure As Code in AWS using Terraform (Updated at 2023-11-13)
# Get Started
To build infrastructure, you need the following tools:
- AWS CLI
- Terraform CLI
- kubectl
```shell
$ terraform init
$ terraform plan
$ terraform apply --auto-approve
```
## kubectl CLI
```shell
$ aws eks --region update-kubeconfig --name
```## Grafana Dashboard
If you select `ClusterIP` as `service.type`, you can connect through port-forwarding as follows.
```shell
$ 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
```├── 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
- [IRSAs in EKS 5.30.1](https://github.com/terraform-aws-modules/terraform-aws-iam/tree/v5.30.1/modules/iam-role-for-service-accounts-eks)
- [eks 19.19.0](https://github.com/terraform-aws-modules/terraform-aws-eks)
- [kms 2.1.0](https://github.com/terraform-aws-modules/terraform-aws-kms)
- [karpenter v19.19.0](https://github.com/terraform-aws-modules/terraform-aws-eks/tree/v19.19.0/modules/karpenter)
- [vpc 5.1.2](https://github.com/terraform-aws-modules/terraform-aws-vpc)
- [vpc-endpoints 5.1.2](https://github.com/terraform-aws-modules/terraform-aws-vpc/tree/v5.1.2/modules/vpc-endpoints)## Helm Release
- [aws-load-balancer-controller 1.6.2](https://artifacthub.io/packages/helm/aws/aws-load-balancer-controller)
- [aws-node-termination-handler 0.21.0](https://artifacthub.io/packages/helm/aws/aws-node-termination-handler)
- [cert-manager v1.13.2](https://artifacthub.io/packages/helm/cert-manager/cert-manager)
- [fluent-bit 0.39.1](https://artifacthub.io/packages/helm/fluent/fluent-bit)
- [prometheus 25.4.0](https://artifacthub.io/packages/helm/prometheus-community/prometheus)
- [grafana 7.0.3](https://artifacthub.io/packages/helm/grafana/grafana)
- [karpenter v0.32.1](https://artifacthub.io/packages/helm/karpenter/karpenter)
- [metrics-server 3.11.0](https://artifacthub.io/packages/helm/metrics-server/metrics-server)