dr-controlplane
Common DC failover service. A three data center etcd quorum and an OCM control plane that exposes the Kubernetes Lease API as the cross data center failover signal, plus the per DC agent and the topology controller.
About this chart
DR Control Plane
DR Control Plane by AppsCode - Common DC failover service for Kubernetes
TL;DR;
$ helm repo add appscode https://charts.appscode.com/stable/
$ helm repo update
$ helm search repo appscode/dr-controlplane --version=v0.1.0
$ helm upgrade -i dr-controlplane appscode/dr-controlplane -n dc-failover --create-namespace --version=v0.1.0
Introduction
This chart deploys a DR Control Plane on a Kubernetes cluster using the Helm package manager.
Prerequisites
- Kubernetes 1.26+
Installing the Chart
To install/upgrade the chart with the release name dr-controlplane:
$ helm upgrade -i dr-controlplane appscode/dr-controlplane -n dc-failover --create-namespace --version=v0.1.0
The command deploys a DR Control Plane on the Kubernetes cluster in the default configuration. The configuration section lists the parameters that can be configured during installation.
Tip: List all releases using
helm list
Uninstalling the Chart
To uninstall the dr-controlplane:
$ helm uninstall dr-controlplane -n dc-failover
The command removes all the Kubernetes components associated with the chart and deletes the release.
Configuration
The following table lists the configurable parameters of the dr-controlplane chart and their default values.
| Parameter | Description | Default |
|---|---|---|
| namespace | Namespace that holds the coordination Leases. Created when createNamespace is true. | dc-failover |
| createNamespace | true | |
| registryFQDN | Docker registry fqdn used to pull dr-controlplane docker images | ghcr.io |
| image | Container image for the dr-agent, dr-topology, and drctl binaries (one image, three binaries). | ghcr.io/appscode/dr-controlplane |
| tag | "" # defaults to .Chart.AppVersion | |
| imagePullPolicy | IfNotPresent | |
| imagePullSecrets | [] | |
| etcd.deploy | deploy a three replica StatefulSet for single cluster dev and test. For real multi data center production, set deploy=false and point the control plane at a real etcd whose three members live one per data center (externalEndpoints). | true |
| etcd.replicas | 3 | |
| etcd.image | quay.io/coreos/etcd:v3.6.5 | |
| etcd.storageClassName | "" | |
| etcd.storageSize | 1Gi | |
| etcd.heartbeatIntervalMs | WAN tuning. Set comfortably above the inter data center round trip time so cross DC latency does not trigger spurious etcd elections. | 500 |
| etcd.electionTimeoutMs | 5000 | |
| etcd.member.name | Empty keeps the single cluster StatefulSet (dev and test). Set to this data center's name to deploy the one member that belongs here. | "" |
| etcd.member.advertiseHost | Routable address other data centers reach this member on. Required when name is set. With hostNetwork this is the node's own IP. | "" |
| etcd.member.clientPort | 2379 | |
| etcd.member.peerPort | 2380 | |
| etcd.member.hostNetwork | hostNetwork gives the member a routable address without needing a LoadBalancer per DC, which is how the reference deployment does it. | true |
| etcd.member.hostPath | Data lives on the node, so the member keeps its identity across restarts. | /var/lib/dr-etcd |
| etcd.member.persistence.enabled | Replaces the hostPath volume with a PVC, so the data survives losing the node. | false |
| etcd.member.persistence.existingClaim | "" | |
| etcd.member.persistence.size | 8Gi | |
| etcd.member.persistence.storageClassName | "" | |
| etc |
Deploy dr-controlplane with OpenTenant
Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has dr-controlplane on a Hetzner server. Change the host, add apps from the marketplace, then copy the generated files. Providers and prices are samples, and nothing here is sent anywhere.
- Pick a serverConnect Hetzner, OVHcloud or AWS. The builder starts on Hetzner, the cheapest sample rate.
- Place the chartdr-controlplane is pinned at v0.1.0 in opentenant.yaml. Drag more apps from the marketplace onto a rack.
- ApplySave opentenant.yaml and main.tf from the console, then run the commands below.
# opentenant.yaml, main.tf and dns.tf come from the builder below opentenant validate opentenant.yaml terraform init && terraform apply