---
title: "Prepare the cluster and network"
url: "https://docs.mekodata.ai/byoc/prerequisites/kubernetes-network/"
---

# Prepare the cluster and network

The storage class, load balancer controller, subnet tags, DNS and certificate, and OpenTelemetry Operator that Meko BYOC needs in your cluster

Create the EKS cluster with the [node sizes](/byoc/prerequisites/requirements/#cluster) for your `SIZE`, then add what Meko expects to find in it.

## Storage class

The database stores its data on EBS volumes. Use a storage class that waits for the pod to be scheduled before it creates the volume, so the volume is created in the zone where the pod runs, and that allows volumes to grow. This needs the [Amazon EBS CSI driver](https://docs.aws.amazon.com/eks/latest/userguide/ebs-csi.html) add-on.

```sh
kubectl apply -f - <<'EOF'
apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:
  name: meko-gp3
provisioner: ebs.csi.aws.com
parameters:
  type: gp3
volumeBindingMode: WaitForFirstConsumer
allowVolumeExpansion: true
EOF
```

You name this class in the [database definition](/byoc/deploy-aws/#edit-the-database-definition). A class that binds volumes immediately creates the volume first and pins the pod that uses it to that zone, which can leave a pod that can't be scheduled.

## AWS Load Balancer Controller

The install puts an internal Application Load Balancer (ALB) in front of Meko. The UI, sign-in, and MCP clients (`<address>/mcp`) all use it. The AWS Load Balancer Controller creates the ALB, with its own IAM role, so Meko needs no AWS credentials for it.

[Install the controller](https://docs.aws.amazon.com/eks/latest/userguide/lbc-helm.html) if the cluster doesn't have it, then check:

```sh
kubectl get ingressclass alb
```

The install stops with an error if that class is missing.

## Subnet tags

Tag the cluster's private subnets, in at least two zones, so the controller can place an internal ALB in them:

```sh
aws ec2 create-tags --resources <subnet id> <subnet id> \
  --tags Key=kubernetes.io/role/internal-elb,Value=1
```

Without the tag, the ALB never gets an address. The install waits ten minutes for one and then stops.

## Network access

The ALB is internal, so only networks that can route to your VPC reach Meko. Make sure the people and agents who will use Meko have a path to it, such as a VPC peering, a VPN, or Direct Connect. You can test it from your own network once the install prints the address.

The cluster's nodes need outbound HTTPS to:

| Destination                                                                              | For                                                                                               |
|------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------|
| `quay.io`                                                                                | Meko images and charts                                                                            |
| Docker Hub: `registry-1.docker.io`, `auth.docker.io`, `production.cloudflare.docker.com` | Images for Valkey, the database's bundled PostgreSQL and Prometheus, and the telemetry collectors |
| GitHub Container Registry: `ghcr.io`, `pkg-containers.githubusercontent.com`             | The OpenTelemetry Operator's image                                                                |
| `releases.yugabyte.com`                                                                  | The YugabyteDB Anywhere chart                                                                     |
| AWS: S3, Bedrock, STS                                                                    | Knowledge-base storage, embeddings, and credentials                                               |
| `api.openai.com`                                                                         | Memory extraction                                                                                 |
| Your identity provider                                                                   | Sign-in                                                                                           |
| The Meko control plane                                                                   | The reconcile agent                                                                               |
| Meko's metrics endpoint, and Datadog                                                     | Telemetry                                                                                         |

## DNS and certificate (production)

A proof of concept needs none of this. It is served over plain HTTP at the load balancer's own host name, for a trusted network only. Sign-in tokens and API keys travel unencrypted.

For production, choose a host name for Meko, such as `meko.example.com`, and request a certificate for it in the same AWS account and Region as the cluster:

```sh
aws acm request-certificate --domain-name meko.example.com \
  --validation-method DNS --region <cluster region>
```

Add the validation record ACM gives you to your DNS zone, wait for the certificate to show `ISSUED`, and save its ARN as `ACM_CERT_ARN`. Set `PUBLIC_URL` to `https://meko.example.com`, with no path and no trailing slash. The two go together: the install refuses either one without the other.

The install prints the load balancer's host name at step 2. Create a CNAME record that points your DNS name at it.

## OpenTelemetry Operator

Meko's telemetry collectors are `OpenTelemetryCollector` resources, so nothing ships without the operator. Install it with the contrib collector distribution:

```sh
helm repo add open-telemetry https://open-telemetry.github.io/opentelemetry-helm-charts
helm upgrade --install opentelemetry-operator open-telemetry/opentelemetry-operator \
  -n opentelemetry-operator-system --create-namespace \
  --set admissionWebhooks.certManager.enabled=false \
  --set admissionWebhooks.autoGenerateCert.enabled=true \
  --set manager.collectorImage.repository=otel/opentelemetry-collector-contrib
```

## Next

[Apply your Meko license](/byoc/prerequisites/meko-license/).
