linkerd-failover
by Buoyant
About this chart
linkerd-failover
Homepage: https://linkerd.io
Requirements
Besides Linkerd and the operator itself, since we make use of the TrafficSplit
CRD, it is required to install the linkerd-smi extension.
Configuration
The following Helm values are available:
selector: determines whichTrafficSplitinstances to consider for failover.logLevel,logFormat: for configuring the operators logging.
Installation
The SMI extension and the operator are to be installed in the local cluster (there where the clients consuming the service are located).
Linkerd-smi installation:
helm repo add linkerd-smi https://linkerd.github.io/linkerd-smi
helm repo up
helm install linkerd-smi -n linkerd-smi --create-namespace linkerd-smi/linkerd-smi
Linkerd-failover installation:
# In case you haven't added the linkerd-edge repo already
helm repo add linkerd-edge https://helm.linkerd.io/edge
helm repo up
helm install linkerd-failover -n linkerd-failover --create-namespace --devel linkerd-edge/linkerd-failover
Example
The following TrafficSplit serves as the initial state for a failover setup.
Clients should send requests to the apex service sample-svc. The primary
service that will serve these requests is declared through the
failover.linkerd.io/primary-service annotation, sample-svc in this case.
When sample-svc starts failing, the weights will be switched over the other
backends.
Note that the failover services can be located in the local cluster, or they can point to mirror services backed by services in other clusters (through Linkerd's multicluster functionality).
apiVersion: split.smi-spec.io/v1alpha2
kind: TrafficSplit
metadata:
name: sample-svc
annotations:
failover.linkerd.io/primary-service: sample-svc
labels:
failover.linkerd.io/controlled-by: linkerd-failover
spec:
service: sample-svc
backends:
- service: sample-svc
weight: 1
- service: sample-svc-central1
weight: 0
- service: sample-svc-east1
weight: 0
- service: sample-svc-east2
weight: 0
- service: sample-svc-asia1
weight: 0
Get involved
- Check out Linkerd's source code at GitHub.
- Join Linkerd's user mailing list, developer mailing list, and announcements mailing list.
- Follow @linkerd on Twitter.
- Join the Linkerd Slack.
Requirements
Kubernetes: >=1.20.0-0
Values
| Key | Type | Default | Description |
|---|---|---|---|
| image | object | {"name":"failover","registry":"cr.l5d.io/linkerd","tag":"0.1.3"} | Docker image |
| imagePullSecrets | list | [] | imagePullSecrets to apply to all ServiceAccounts for pulling images from private registries |
| linkerdNamespace | string | "linkerd" | Namespace of the Linkerd core control-plane install |
| logFormat | string | "plain" | Log format (plain or json) |
| logLevel | string | "linkerd=info,warn" | Log level |
| namespaceMetadata.image.name | string | "extension-init" | Docker image name for the namespace-metadata instance |
| namespaceMetadata.image.pullPolicy | string | "IfNotPresent" | Pull policy for the namespace-metadata instance |
| namespaceMetadata.image.registry | string | "cr.l5d.io/linkerd" | Docker registry for the namespace-metadata instance |
| namespaceMetadata.image.tag | string | "v0.1.0" | Docker image tag for the namespace-metadata instance |
| selector | string | nil | Determines which TrafficSplit instances to consider for failover. If empty, defaults to failover.linkerd.io/controlled-by={{ .Release.Name }} |
Autogenerated from chart metadata using helm-docs v1.11.0
Deploy linkerd-failover with OpenTenant
Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has linkerd-failover 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 chartlinkerd-failover is pinned at v0.1.3 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