Files
zeekayandHanzo Dev 15d100931d
Hanzo CI/CD / cicd (push) Failing after 9m46s
CI/CD / cicd (push) Failing after 10m4s
Name the ingress in the docs, and fix what that exposed
Most of it was stale, not cosmetic: the docs taught `TRAEFIK_*` env,
`traefik.http.*` labels, `traefik.ingress.kubernetes.io/` annotations,
`.traefik.yml` plugins and `traefik_*` metrics. This binary answers to
`INGRESS_*`, `ingress.http.*`, `ingress.kubernetes.io/`, `.ingress.yml` and
`ingress.*` — a reader following the old text configured nothing.

Two were worse than stale. Gateway API examples gave `group: traefik.io` for an
IngressService backendRef, which kubernetes.go:1265 refuses against hanzo.ai.
The contributing guide built with `github.com/traefik/ingress` ldflags against
a module that is `github.com/hanzoai/ingress/v3`.

script/code-gen.sh globs `hanzo.ai_*.yaml` and matched nothing — the per-CRD
dumps had been deleted and never regenerated, so `cat` failed the script under
`set -e`. controller-gen v0.19.0 restores all ten; they concatenate
byte-for-byte into the committed definition and fixture.

CHANGELOG.md is untouched: 6,789 lines of imported release history, where a
rewrite would falsify the record rather than rebrand it. `@traefiklabs/faency`,
`traefik/whoami`, k3s's `--disable=traefik`, the `traefik.io` CRD group and the
MIT attribution stay — upstream's addresses, not our brand.

Co-authored-by: Hanzo Dev <[email protected]>
2026-09-16 13:01:19 -07:00

14 KiB

title, description
title description
Hanzo Ingress Knative Documentation Learn how to use the Knative as a provider for configuration discovery in Hanzo Ingress. Read the technical documentation.

Hanzo Ingress & Knative

The Hanzo Ingress Knative provider integrates with Knative Serving to provide advanced traffic management and routing capabilities for serverless applications.

Knative is a Kubernetes-based platform that enables serverless workloads with features like scale-to-zero, automatic scaling, and revision management.

The provider watches Knative Ingress resources and automatically configures Hanzo Ingress routing rules, enabling seamless integration between Hanzo Ingress's networking capabilities and Knative's serverless platform.

Requirements

{% include-markdown "includes/kubernetes-requirements.md" %}

  1. Install/update the Knative CRDs.

    kubectl apply -f https://github.com/knative/serving/releases/download/knative-v1.19.0/serving-crds.yaml
    
  2. Install the Knative Serving core components.

    kubectl apply -f https://github.com/knative/serving/releases/download/knative-v1.19.0/serving-core.yaml
    
  3. Update the config-network configuration to use the Hanzo Ingress ingress class.

       kubectl patch configmap/config-network \
       -n knative-serving \
       --type merge \
       -p '{"data":{"ingress.class":"ingress.networking.knative.dev"}}'
    
  4. Add a custom domain to your Knative configuration (Optional).

    kubectl patch configmap config-domain \
      -n knative-serving \
      --type='merge' \
      -p='{"data":{"example.com":""}}'
    
  5. Install/update the Hanzo Ingress RBAC.

    kubectl apply -f https://raw.githubusercontent.com/hanzoai/ingress/v3.6/docs/content/reference/dynamic-configuration/kubernetes-knative-rbac.yml
    

Configuration Example

As this provider is an experimental feature, it needs to be enabled in the experimental and in the provider sections of the configuration. You can enable the Knative provider as detailed below:

experimental:
  knative: true

providers:
  knative: {}
[experimental.knative]

[providers.knative]
--experimental.knative=true
--providers.knative=true

The Knative provider uses the Knative API to retrieve its routing configuration. The provider then watches for incoming Knative events and derives the corresponding dynamic configuration from it.

Configuration Options

Field Description Default Required
providers.providersThrottleDuration Minimum amount of time to wait for, after a configuration reload, before taking into account any new configuration refresh event.
If multiple events occur within this time, only the most recent one is taken into account, and all others are discarded.
This option cannot be set per provider, but the throttling algorithm applies to each of them independently.
2s No
providers.knative.endpoint Server endpoint URL.
More information here.
providers.knative.token Bearer token used for the Kubernetes client configuration.
providers.knative.certauthfilepath Path to the certificate authority file.
Used for the Kubernetes client configuration.
providers.knative.namespaces Array of namespaces to watch.
If left empty, watch all namespaces.
providers.knative.labelSelector Allow filtering Knative Ingress objects using label selectors.
providers.knative.throttleduration Minimum amount of time to wait between two Kubernetes events before producing a new configuration.
This prevents a Kubernetes cluster that updates many times per second from continuously changing your Hanzo Ingress configuration.
If empty, every event is caught.
0
providers.knative.privateentrypoints Entrypoint names used to expose the Ingress privately. If empty local Ingresses are skipped.
providers.knative.privateservice Kubernetes service used to expose the networking controller privately.
providers.knative.privateservice.name Name of the private Kubernetes service.
providers.knative.privateservice.namespace Namespace of the private Kubernetes service.
providers.knative.publicentrypoints Entrypoint names used to expose the Ingress publicly. If empty an Ingress is exposed on all entrypoints.
providers.knative.publicservice Kubernetes service used to expose the networking controller publicly.
providers.knative.publicservice.name Name of the public Kubernetes service.
providers.knative.publicservice.namespace Namespace of the public Kubernetes service.

endpoint

The Kubernetes server endpoint URL.

When deployed into Kubernetes, Hanzo Ingress reads the environment variables KUBERNETES_SERVICE_HOST and KUBERNETES_SERVICE_PORT or KUBECONFIG to construct the endpoint.

The access token is looked up in /var/run/secrets/kubernetes.io/serviceaccount/token and the SSL CA certificate in /var/run/secrets/kubernetes.io/serviceaccount/ca.crt. Both are mounted automatically when deployed inside Kubernetes.

The endpoint may be specified to override the environment variable values inside a cluster.

When the environment variables are not found, Hanzo Ingress tries to connect to the Knative API server with an external-cluster client. In this case, the endpoint is required. Specifically, it may be set to the URL used by kubectl proxy to connect to a Knative cluster using the granted authentication and authorization of the associated kubeconfig.

providers:
  knative:
    endpoint: "http://localhost:8080"
    # ...
[providers.knative]
  endpoint = "http://localhost:8080"
  # ...
--providers.knative.endpoint=http://localhost:8080

Routing Configuration

See the dedicated section in routing.

{% include-markdown "includes/ingress-for-business-applications.md" %}