> ## Documentation Index
> Fetch the complete documentation index at: https://sariva.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Amazon EKS

> What your existing EKS cluster must have — the shared baseline for both deployment paths, plus the extra capacity the CFK path needs to run Confluent Platform itself.

**This page answers one question: what must your EKS cluster have?** The answer has two parts, because the two deployment paths put different things on the cluster:

| Deployment path | What runs on this EKS cluster | You need |
| - | - | - |
| **AWS EKS + Confluent Cloud** | The **Sariva platform** only — Kafka lives in Confluent Cloud | Part 1 |
| **AWS EKS + Confluent Platform (CFK)** | The **Sariva platform AND Confluent Platform itself** (brokers, KRaft controllers, Schema Registry, CFK operator) | Part 1 **+** Part 2 |

We expect you to already have an EKS cluster; this page is about confirming it qualifies. If you don't have one yet, expand **[Don't have an EKS cluster yet?](#dont-have-an-eks-cluster-yet)** at the bottom.

## Part 1 — hosting the Sariva platform (required on BOTH paths)

* [ ] A **running EKS cluster** on a currently-supported Kubernetes version (this guide's examples use 1.30; 1.27+ is fine)
* [ ] **`kubectl` access** — your IAM identity can reach the cluster (`kubectl get nodes` returns Ready nodes)
* [ ] The **Amazon EBS CSI Driver** add-on, **with an attached IAM role** (Pod Identity or IRSA) — required for the Sariva platform's persistent volume
* [ ] The **eks-pod-identity-agent** add-on
* [ ] *(Optional — for pod-health CPU/mem headroom)* The **metrics-server** add-on — EKS doesn't install it by default; without it pod status/restarts still work, but headroom reports "unavailable"
* [ ] A **default `gp3` StorageClass** — the EBS CSI add-on does **not** create one (the #1 trap)
* [ ] An **AWS IAM admin identity** with Console access — you'll create IAM roles during setup (the Sariva platform pod's AWS identity role is wired later, on the [pod AWS identity page](https://sariva.mintlify.site/install-setup/irsa.md))

On the Confluent Cloud path, Part 1 is the whole page — jump to [Verify in one minute](#verify-in-one-minute).

## Part 2 — additionally running Confluent Platform (CFK path ONLY)

On **AWS EKS + Confluent Platform (CFK)**, this same cluster also runs Kafka itself — so on top of Part 1 it needs capacity and storage for the data plane:

* [ ] **Node capacity for Confluent Platform.** The POC footprint is the full component set — 3 brokers + 3 KRaft controllers + Schema Registry + Connect + REST Proxy (plus the CFK operator and the Sariva pod) — validated on **3× t3.large** — broker pods spread one per node, so fewer or smaller nodes leave a broker `Pending`. Size it properly: [EKS sizing for CFK/CP](https://sariva.mintlify.site/prerequisites/aws/sizing.md).
* [ ] **The default `gp3` StorageClass serves the data plane too** — on this path it provisions every **broker and KRaft volume**, not just the Sariva pod's PVC. Without it, `data0-kafka-*` and `data0-kraftcontroller-*` PVCs hang `Pending` and the cluster never comes up.

## Verify in one minute

```bash theme={null}
kubectl get nodes
# → your nodes, STATUS=Ready

kubectl get pods -n kube-system | grep ebs-csi
# → ebs-csi-controller-* and ebs-csi-node-* pods, all Running

kubectl get storageclass
# → at least one row marked (default), provisioner ebs.csi.aws.com
```

If all three look right, your cluster is ready — continue to the next prerequisite. If a piece is missing, fix it below.

⚠WARNING

**Can't `kubectl get nodes`?** (`the server has asked for the client to provide credentials`) — the cluster was most likely created while signed in as **root**, which gives only the root principal a Kubernetes-layer identity. Grant your IAM user access at the **AWS layer**:

```bash theme={null}
aws eks create-access-entry --cluster-name <cluster> --region <region> \
  --principal-arn arn:aws:iam::<account>:user/<iam-user> --type STANDARD

aws eks associate-access-policy --cluster-name <cluster> --region <region> \
  --principal-arn arn:aws:iam::<account>:user/<iam-user> \
  --policy-arn arn:aws:eks::aws:cluster-access-policy/AmazonEKSClusterAdminPolicy \
  --access-scope type=cluster
```

Note the ARN namespace — `arn:aws:eks::aws:cluster-access-policy/...` (EKS-managed), **not** `arn:aws:iam::aws:policy/...` (the IAM namespace returns `InvalidParameterException`).

## Add-ons: EBS CSI Driver (if missing)

The Sariva platform stores state on a PersistentVolume — and on the CFK path the brokers and KRaft controllers do too — so the EBS CSI Driver must be installed **and** able to call AWS:

1. EKS Console → your cluster → **Add-ons** → **Get more add-ons** → tick **Amazon EBS CSI Driver** and **eks-pod-identity-agent** → install.
2. Attach an IAM role to the driver: **Add-ons → Amazon EBS CSI Driver → Edit → EKS Pod Identity → Create recommended role → Save.** Without this role the driver pods run but can't provision volumes.

## Add-on: metrics-server (optional — pod-health headroom)

Sariva can report a pod's **CPU/memory headroom** (live usage vs limits) when you ask. That reads the `metrics.k8s.io` API, served by [metrics-server](https://github.com/kubernetes-sigs/metrics-server) — which EKS does **not** install by default. Add it as the **EKS managed add-on** (cleanest, and it stays patched):

* **Console:** EKS → your cluster → **Add-ons** → **Get more add-ons** → tick **metrics-server** → install.
* **CLI:** `aws eks create-addon --cluster-name <cluster> --addon-name metrics-server --region <region>`
* **eksctl:** add `- name: metrics-server` under `addons:` in your cluster config.

Verify with `kubectl top nodes` (give the add-on \~1 minute after install). Without metrics-server, pod status / restarts / events still work — only CPU/mem headroom reports **"unavailable."**

## Default `gp3` StorageClass (required)

⚠WARNING

**The EBS CSI Driver add-on does NOT create a default StorageClass.** The driver pods run, but no StorageClass gets the `is-default-class` annotation — so the Sariva platform's PVC hangs `Pending` indefinitely — and on the CFK path, so do all broker and KRaft volumes. Apply this **before** `helm install`.

Save as `gp3-storageclass.yaml`:

```yaml theme={null}
apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
  name: gp3
  annotations:
    storageclass.kubernetes.io/is-default-class: "true"
provisioner: ebs.csi.aws.com
parameters:
  type: gp3
  fsType: ext4
  encrypted: "true"
volumeBindingMode: WaitForFirstConsumer
allowVolumeExpansion: true
reclaimPolicy: Delete
```

```bash theme={null}
kubectl apply -f gp3-storageclass.yaml
kubectl get storageclass
# → gp3 (default)   ebs.csi.aws.com   Delete   WaitForFirstConsumer   true
```

`gp3` is faster and \~20% cheaper than gp2; `encrypted: "true"` uses the AWS-managed KMS key (often required for compliance); `WaitForFirstConsumer` places the volume in the pod's AZ (critical on multi-AZ clusters).

## Don't have an EKS cluster yet?

> [accordion] Create a cluster (only if you don't already have one)
>
> This is directional guidance for first-time setup, not a required step if you already have a cluster.
>
> ⚠WARNING
>
> **Create it as an IAM user, not root.** Creating the cluster while signed in as root gives only the root principal a Kubernetes identity, and your IAM CLI then can't `kubectl get nodes`. Use the IAM admin identity from your prerequisites (Console password + MFA).
>
> **1. Create two IAM roles first** (IAM Console → Roles → Create role) — the create-cluster wizard requires both:
>
> * **Cluster role** — trusted by `eks.amazonaws.com`, with `AmazonEKSClusterPolicy`. Convention: `<cluster>-eks-cluster-role`.
> * **Node group role** — trusted by `ec2.amazonaws.com`, with `AmazonEKSWorkerNodePolicy`, `AmazonEC2ContainerRegistryReadOnly`, `AmazonEKS_CNI_Policy`. Convention: `<cluster>-eks-node-role`.
>
> **2. Create the cluster** (EKS Console → Clusters → Create):
>
> ⚠WARNING
>
> **Turn EKS Auto Mode OFF.** On **Configuration options**, choose **Custom** and set **Use EKS Auto Mode** to **OFF** — Auto Mode bundles its own block storage and bypasses the EBS CSI Driver flow this guide relies on.
>
> | Field | Value |
> | - | - |
> | Configuration options | **Custom** |
> | Use EKS Auto Mode | **OFF** |
> | Kubernetes version | 1.30 or newer |
> | Cluster service role | the cluster role above |
> | VPC | default VPC is fine for first setup; production uses a dedicated VPC |
>
> On **Add-ons**, tick **Amazon EBS CSI Driver** + **eks-pod-identity-agent** (and **metrics-server** too, if you want pod-health CPU/mem headroom — see the metrics-server add-on section above). Create (12–15 min to `Active`), then attach the EBS CSI Pod Identity role as in the add-ons section above.
>
> **3. Add a managed node group** (Compute → Add node group): node role from step 1, AMI `AL2023_x86_64_STANDARD`. Sizing depends on your path: **Confluent Cloud path** — `t3.medium`, desired/min/max `2 / 2 / 4`, 20 GiB disk (only Sariva runs here). **CFK path** — the cluster also runs Kafka; use [EKS sizing for CFK/CP](https://sariva.mintlify.site/prerequisites/aws/sizing.md) (POC baseline: 3× `t3.large`).
>
> **4. Wire kubectl:**
>
> ```bash theme={null}
> aws eks update-kubeconfig --name <cluster> --region <region>
> kubectl get nodes
> ```
>
> **CLI alternatives:** `eksctl create cluster --name <c> --region <r> --node-type t3.medium --nodes 2 --with-oidc --managed`; or Terraform (`aws_eks_cluster` + `aws_eks_node_group` + `aws_eks_addon` — the wizard's scaffold does **not** create EKS, bring your own); or `aws eks create-cluster` + `create-nodegroup` + `create-addon`. For headroom, also add the metrics-server add-on (`aws eks create-addon --addon-name metrics-server …`, or `- name: metrics-server` in an eksctl config).
>
> Finish with the **Verify in one minute** checks above before running the wizard.

## Continue the deployment path

This page is shared by both deployment paths — pick the next step for **yours**:

> [card] [Confluent Cloud path — next: account access](https://sariva.mintlify.site/prerequisites/confluent-cloud/overview.md)
>
> On **AWS EKS + Confluent Cloud**, set up Confluent Cloud account access and create the up-front Cloud API keys.

> [card] [CFK path — next: EKS sizing for CFK/CP](https://sariva.mintlify.site/prerequisites/aws/sizing.md)
>
> On **AWS EKS + Confluent Platform (CFK)**, size the nodes that will run Kafka itself before choosing the package.

> [card] [Back: AWS EKS + Confluent Cloud](https://sariva.mintlify.site/deploy/aws-eks-cc.md)
>
> Return to the Confluent Cloud path map.

> [card] [Back: AWS EKS + Confluent Platform (CFK)](https://sariva.mintlify.site/deploy/aws-eks-cfk.md)
>
> Return to the CFK path map.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.