haptic

command
v0.6.0-rc.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 17, 2026 License: Apache-2.0 Imports: 90 Imported by: 0

Documentation

Overview

Package main provides the CLI entrypoint for the HAProxy template ingress controller.

The controller accepts configuration via CLI flags, environment variables, or defaults:

  • HAProxyTemplateConfig CRD name: --crd-name flag, CRD_NAME env var, or "haproxy-config" default
  • Secret name: --secret-name flag, SECRET_NAME env var, or "haproxy-credentials" default
  • Webhook cert directory: --webhook-cert-dir flag or WEBHOOK_CERT_DIR env var (directory holding tls.crt/tls.key; optional, empty disables the webhook)
  • Webhook HTTPS port: WEBHOOK_PORT env var (default 9443)
  • Debug HTTP port: --debug-port flag or DEBUG_PORT env var (default 0 = disabled)
  • Metrics HTTP port: METRICS_PORT env var (default 9090; 0 disables)
  • Kubeconfig: --kubeconfig flag (for out-of-cluster development)

The controller runs until receiving SIGTERM or SIGINT, at which point it performs graceful shutdown.

Package main — `haptic preflight`.

Renders the bundled chart with an operator's OWN values and runs the checks the controller runs on startup, before anything reaches the cluster.

The chart's CI can only prove the DEFAULTS work; it never sees an operator's values.yaml. So the first thing that evaluates them is the load gate, which is fail-closed — making a bad configuration a crash-looping controller rather than a failed deploy. This moves that verdict into the pipeline.

In-process on purpose: the chart, the renderer and the load gate all live in this binary, so a pipeline needs neither helm nor yq, and the chart validated is the one shipped in the image being deployed.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL