Traefik (traefik-infra)
traefik-infra is not part of the OLIVE platformIt is provided as-is to make setup easier — not maintained, patched or supported as part of the platform release, and not covered by OLIVE support. Traefik Proxy is third-party software with its own licence, release cycle and security advisories; tracking and applying those is yours regardless of how you installed it.
What OLIVE does stand behind is the contract in Ingress Requirements. Meet it however you like.
Why OLIVE needs it
Traefik is the only supported ingress controller from 1.3. Every OLIVE chart that exposes something writes a plain Ingress with ingressClassName: traefik, the websecure entry point, and traefik.io/v1alpha1 Middleware objects in its own namespace. Those middlewares are how authentication, prefix stripping, request buffering and the login redirect are applied at the edge.
Optional, and narrower in scope than the other four. On RKE2 you already have Traefik — bundled, as a DaemonSet in kube-system — and all you need to add is the redirectErrors plugin. This chart exists for clusters where Traefik is not already installed, which in practice means Amazon EKS, where it also has to be put behind a load balancer.
| Your cluster | What you need |
|---|---|
| RKE2 | Traefik is already there. Add the redirectErrors plugin to its static configuration via a HelmChartConfig in kube-system. You do not need this chart |
| EKS, or any cluster without Traefik | Install Traefik. This chart does it, behind an AWS NLB, with the plugin already vendored |
The redirectErrors plugin
This is the part worth reading even if you do not use the chart, because it is the OLIVE requirement that is hardest to satisfy from the ingress documentation alone.
OLIVE renders a Middleware of type plugin.redirectErrors. A Traefik plugin registered under exactly that name must be loaded, or Traefik rejects the middleware and the route fails — so an unauthenticated user meets an error page instead of a login page.
| Module | github.com/indivisible/redirecterrors |
| Version | v0.1.0 |
| Middleware name | redirectErrors — fixed; the OLIVE charts reference it by that name |
| What it does | Converts the 401/403 from a forwardAuth endpoint into a 302 to the start URL |
Traefik can load a plugin in two ways, and which you choose has an operational consequence.
Local plugin — the source is vendored and mounted
This is what traefik-infra does. The plugin source is held in the chart under files/plugins/redirecterrors/, rendered into a ConfigMap (traefik-plugin-redirecterrors) and mounted where Traefik looks for local plugins.
localPlugin:
redirectErrors:
enabled: true
version: v0.1.0 # informational — bump together with the files
Two reasons this is the better shape:
- No egress to
plugins.traefik.iois needed. The plugin is already on disk. - What runs is exactly what is in Git, reviewable and pinned, rather than whatever the plugin registry serves at pod start.
The ConfigMap syncs in an earlier wave than the Deployment, because the pod mounts it and would otherwise sit in ContainerCreating.
Remote plugin — fetched at every pod start
traefik:
experimental:
plugins:
redirectErrors:
moduleName: github.com/indivisible/redirecterrors
version: v0.1.0
Traefik downloads it from plugins.traefik.io each time a pod starts — not once at install. With abortOnPluginFailure set, a cluster without egress to that host produces unable to download plugin … context deadline exceeded and Traefik exits. The ingress controller then does not come back, which takes the whole platform offline rather than degrading it.
That makes a remote plugin a dependency on a third-party service in your ingress controller's startup path. Use it only where the pods genuinely have that egress and you accept the coupling; prefer the local form otherwise.
After changing the plugin files or its configuration, restart the controller — nothing reloads it:
kubectl -n <namespace> rollout restart deploy/<release>
Using the traefik-infra chart
The chart wraps the upstream Traefik chart and adds only what the platform needs around it: the namespace, an optional default TLSStore, a NetworkPolicy, the vendored plugin ConfigMap, and render-time guards.
| Chart version | 0.1.5 |
| Traefik | v3.7.13, via upstream chart 41.5.0 |
| Shared library | utilities 1.11.2 — the same version every other OLIVE chart pins |
| Built for | EKS, behind an AWS Network Load Balancer provisioned by the AWS Load Balancer Controller |
What comes from the upstream chart: the Deployment, the Service, RBAC, the IngressClass and the traefik.io CRDs. Everything under the traefik: key in values is passed through verbatim, and because the upstream chart ships a values.schema.json, a key that does not exist in that version fails helm template loudly rather than being ignored.
The contract it guarantees
templates/validate.yaml refuses values that would break what the OLIVE charts assume. Each guard can be relaxed deliberately, which is the point — they fail at render time with a reason rather than at runtime with a timeout.
| Guard | Default | Refuses |
|---|---|---|
requireRedirectErrorsPlugin | true | Values with no redirectErrors plugin — the express and fastapi charts need it |
requireAwsLoadBalancerController | true | A LoadBalancer Service without the AWS LB Controller annotations |
allowCrossNamespace | false | providers.kubernetesCRD.allowCrossNamespace: true — OLIVE references middlewares in their own namespace only |
allowExternalIngressClass | false | ingressClass.enabled: false, unless the IngressClass is deliberately owned elsewhere |
allowNamespacedRbac | false | rbac.namespaced: true, which would make Traefik serve only its own namespace and ignore every OLIVE Ingress |
requireHA | false | Fewer than two replicas, when you turn it on |
The IngressClass is created as traefik and set as the cluster default, and the guard checks it matches global.ingress.className — which is what every OLIVE chart resolves. Both Kubernetes providers are enabled, since OLIVE uses standard Ingress objects plus Middleware CRDs.
What the Argo CD project must permit
Installing Traefik creates cluster-scoped objects, so a restricted AppProject refuses the sync with ... is not permitted in project. This is the project the traefik-infra Application runs in — not the OLIVE platform's project, which installs no CRDs and only needs traefik.io Middleware namespaced. See Argo CD AppProject.
clusterResourceWhitelist:
- group: ''
kind: Namespace
# The traefik.io and hub.traefik.io CRDs, from the upstream subchart's crds/ folder
- group: 'apiextensions.k8s.io'
kind: CustomResourceDefinition
- group: 'networking.k8s.io'
kind: IngressClass
- group: 'rbac.authorization.k8s.io'
kind: ClusterRole
- group: 'rbac.authorization.k8s.io'
kind: ClusterRoleBinding
Namespaced, beyond the usual ConfigMap / Service / ServiceAccount / Deployment / NetworkPolicy set: traefik.io TLSStore.
Listing the individual CRDs is neither possible nor necessary — an AppProject whitelists by Kind, and every CRD is the same Kind. One CustomResourceDefinition entry covers all of them.
skipCrds and a missing Middleware CRD look like different problemsHelm applies a chart's crds/ directory only when the Application does not set helm.skipCrds: true. Leave it unset here. With it set and no admin-applied CRDs, Traefik installs and runs, and the failure surfaces later and elsewhere: every OLIVE chart's Middleware object is rejected as an unknown Kind, so routes exist with no authentication, prefix stripping or login redirect attached.
If the project may not create cluster-scoped objects
traefik-infra ships an overlay for exactly this, used with helm.skipCrds: true and values-no-cluster-resources.yaml. A cluster administrator then creates the CRDs, the ClusterRole, the ClusterRoleBinding and the IngressClass once per cluster, and again on every Traefik chart bump, and the Application installs the rest.
Two things decide whether it works:
- Render the
ClusterRolefrom the chart rather than writing one by hand. The chart's version also grantsingresses/status, whichpublishedServiceneeds, and the reads forMiddlewareandTLSStore. - The admin objects are bound to the ServiceAccount named after the release, in the release namespace. The release name and namespace the admin renders with must match the Application's, or Traefik runs with no permissions and reports an empty configuration rather than an error.
The chart's README carries the exact commands under "Installing without cluster-scoped rights".
Namespace
Leave namespace.name empty and let the Argo CD Application's destination namespace decide it. Mesh enrollment of the ingress gateway is a separate, deliberate step — see Service Mesh, traefikEnrollment and exemptions.traefik.
Installing without cluster-scoped rights
For an Argo CD project that may not create CRDs, ClusterRoles, ClusterRoleBindings or IngressClasses, the chart ships an overlay:
helm:
skipCrds: true # required in the Argo CD Application
valueFiles:
- values-no-cluster-resources.yaml
- <cluster>.yaml
A cluster administrator creates those objects once, bound to the ServiceAccount named after the release in the release namespace — so the release name and namespace must match what the administrator rendered. The chart's README has the detail.
Behind a cloud load balancer
Keycloak and OAuth2 Proxy rely on the X-Forwarded-* headers Traefik sets, so Traefik has to trust the load balancer in front of it — forwardedHeaders.trustedIPs on the entry points, or the PROXY protocol on an NLB. Without that, redirects use the wrong scheme and every client address is the load balancer's. See Ingress Requirements.
Related
- Ingress Requirements — the contract: hostnames, the behaviours the controller must support, and TLS
- Networking — the
NetworkPolicymodel, and why the ingress-controller selector has to match real pods - Infrastructure Charts — the other four, and the as-is terms that apply to all of them