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

# Networking

> The load balancers, DNS records and certificates your Tembo installation needs.

The chart creates the Kubernetes resources that expose Tembo. Your cluster's controllers turn them into load balancers, DNS records and certificates.

***

## What the chart creates

With `ingress.host: tembo.example.com`:

| Resource | Name | Serves | Who connects |
| - | - | - | - |
| Ingress `tembo` | `tembo.example.com` | The web app and API | Users and webhooks |
| Ingress `tembo-previews` | `*.previews.tembo.example.com` | Computer previews and `tembo service` URLs | Users' browsers |
| Ingress `tembo-public`, with `ingress.public` | `api.tembo.example.com` | Webhooks and other provider calls (see [Public API host](https://docs.tembo.io/features/self-hosted/kubernetes/configuration.md#public-api-host)) | Providers |
| Service `tembo-sandbar-hosts` (internal load balancer) | `sandbar.tembo.example.com` | Preview tunnels | Agent hosts |
| Services `tembo-postgresql-hosts` and `tembo-redis-hosts` (internal load balancers) | `postgres.tembo.example.com`, `redis.tembo.example.com` | The bundled Postgres and Redis | Agent hosts |

* The internal Services carry their DNS name in an `external-dns.kubernetes.io/hostname` annotation.
* The Postgres and Redis Services exist only with the bundled data stores and `compute.mode: controller`.
* Previews are on by default from chart 0.6.0, with Tembo releases later than 0.2.892. To turn them off, set `sandbar.enabled: false`.

***

## What you set up

### 1. An Ingress controller

It turns both Ingresses into load balancers, so users and webhooks can reach Tembo. Set `ingress.className` and any `ingress.annotations` your controller needs. The previews' Ingress gets the same ones.

For cloud-specific Ingress settings, follow [AWS prerequisites](https://docs.tembo.io/features/self-hosted/kubernetes/prerequisites/aws.md#ingress-and-certificates) or [GCP prerequisites](https://docs.tembo.io/features/self-hosted/kubernetes/prerequisites/gcp.md#ingress-and-certificates). With another controller, configure its annotations and TLS Secrets directly.

### 2. DNS

Every name in the table must resolve to its load balancer: browsers find Tembo by name, and agent hosts find Sandbar, Postgres and Redis by name.

* **With [external-dns](https://github.com/kubernetes-sigs/external-dns):** it reads the Ingresses' hosts and the Services' annotations and creates the records.
* **Without it:** create the records yourself once the load balancers exist (`kubectl -n tembo get ingress,svc`).

### DNS for internal services

Use private DNS for `postgres.<your-host>`, `redis.<your-host>` and `sandbar.<your-host>`. They only need to resolve from the VPC where agent hosts run. Prefer external-dns to maintain these records from the chart's Service annotations, instead of copying load balancer addresses by hand. See [AWS DNS](https://docs.tembo.io/features/self-hosted/kubernetes/prerequisites/aws.md#dns) or [GCP DNS](https://docs.tembo.io/features/self-hosted/kubernetes/prerequisites/gcp.md#dns) for the provider setup.

Keep the public app and preview records in your public DNS provider. If you use external-dns, configure its public and private zone filters so the internal Service records go only to private zones. Check name resolution from the hosts' VPC before starting sessions.

Internal load balancers are still billed while hosts are scaled to zero. Include their forwarding rules, the public Ingresses, cluster nodes, storage and NAT in your idle-cost estimate; rates depend on the region and network setup.

### 3. TLS certificates

Tembo is served over HTTPS, so you need two certificates:

* `tembo.example.com`
* `*.previews.tembo.example.com`. A `*.example.com` certificate doesn't cover it.

With `ingress.public`, you also need a certificate for its hostname. Cloud-managed certificates are covered in the provider prerequisites linked above.

If your Ingress controller uses Kubernetes TLS Secrets, [cert-manager](https://cert-manager.io) can issue them:

* Name the app's Secret in `ingress.tls.secretName`. The previews' Secret is `tembo-previews-tls` by default; override it with `ingress.previews.tlsSecretName`.
* With `ingress.public`, name its Secret in `ingress.public.tlsSecretName`.
* Add a `cert-manager.io/cluster-issuer` annotation to `ingress.annotations`.
* Wildcards need a ClusterIssuer that uses DNS-01.

If the previews certificate is missing, only previews fail. The web app and API keep working.

***

## Need Help?

If you run into any issues, contact [support@tembo.io](mailto:support@tembo.io).


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