authgateway
by Labs64
Helm chartv0.15.21App 0.1.10Verified publisher
Labs64.IO :: Auth Gateway (ForwardAuth + Middlewares)
About this chart
authgateway
Labs64.IO :: Auth Gateway (ForwardAuth + Middlewares)
Homepage: https://labs64.io
Maintainers
| Name | Url | |
|---|---|---|
| Labs64 | [email protected] | https://labs64.io |
Source Code
- https://github.com/Labs64/labs64.io-helm-charts
- https://github.com/Labs64/labs64.io-authgateway/tree/master/traefik
Requirements
| Repository | Name | Version |
|---|---|---|
| file://../chart-libs | chart-libs | 0.8.12 |
Values
| Key | Type | Default | Description |
|---|---|---|---|
| affinity | object | {} | |
| applicationType | string | "python" | Security response headers are now emitted as a native Gateway API ResponseHeaderModifier filter on each HTTPRoute rule; the canonical values live in the chart-libs "chart-libs.securityHeaders" helper. (The former Traefik security-headers Middleware has been removed.) |
| authGateway | object | {"address":"","authResponseHeaders":["X-Auth-User","X-Auth-Scopes","X-Auth-Tenant","X-Request-ID"],"maxResponseBodySize":8192,"port":8081,"serviceName":"authgateway","trustForwardHeader":false} | ForwardAuth middleware configuration (OIDC/JWT validation via this chart's own authgateway container) |
| authGateway.address | string | "" | Full URL override for the /auth endpoint; when empty the address is derived as http://..svc.cluster.local:/auth |
| authGateway.authResponseHeaders | list | ["X-Auth-User","X-Auth-Scopes","X-Auth-Tenant","X-Request-ID"] | Identity headers copied from the Auth Gateway response onto the upstream request (the Auth Gateway emits every one on each 2xx, so client values can never pass through) |
| authGateway.maxResponseBodySize | int | 8192 | Maximum size (bytes) of the Auth Gateway's /auth response Traefik will read. The response carries only identity headers and no body, so this is a DoS guard, not a functional limit — set well above authResponseHeaders' combined size. |
| authGateway.port | int | 8081 | Service port of the Auth Gateway container |
| authGateway.serviceName | string | "authgateway" | Service name backing the ForwardAuth address. Must match fullnameOverride above since the Auth Gateway Service is rendered by this same chart. |
| authGateway.trustForwardHeader | bool | false | Pass a caller-supplied X-Forwarded-Method / X-Forwarded-Uri on to the Auth Gateway instead of the method and path Traefik actually serves. Keep it false: the Auth Gateway authorises whatever those two headers name, so with true a caller behind a trusted proxy (the entry point's forwardedHeaders.trustedIPs, e.g. a load balancer that passes request headers through) could have a protected route checked as a public one. |
| autoscaling | object | {"enabled":false,"maxReplicas":3,"minReplicas":1,"targetCPUUtilizationPercentage":80} | This section is for setting up autoscaling more information can be found here: https://kubernetes.io/docs/concepts/workloads/autoscaling/ |
| buffering | object | {"enabled":true,"maxRequestBodyBytes":2621440} | Buffering middleware configuration (limits payload sizes to prevent OOM / large event attacks) |
| buffering.enabled | bool | true | Enable the shared buffering middleware |
| buffering.maxRequestBodyBytes | int | 2621440 | Maximum allowed request body size in bytes (default 2.5MB) |
| cerbos | object | {"url":"http://labs64io-authz-pdp:3592"} | Central Cerbos PDP HTTP endpoint (the authorization decision). |
| chart-libs | object | {} | Values passed to the chart-libs library dependency (present so the generated schema accepts the key Helm injects for the dependency) @schema type: object additionalProperties: true @schema |
| compress | object | {"enabled":true,"excludedContentTypes":["image/png","image/jpeg","image/gif","image/webp","application/grpc"],"minResponseBodyBytes":1024} | Response-compression middleware (edge optimization for all modules routed through Traefik) |
| compress.enabled | bool | true | Enable the shared compress middleware |
| compress.excludedContentTypes | list | ["image/png","image/jpeg","image/gif","image/webp","application/grpc"] | Content types excluded from compression (already-compressed formats) |
| compress.minResponseBodyBytes | int | 1024 | Do not compress responses below this size (bytes) |
| enabled | bool | true | |
| env | list | [] | Raw environment entries appended verbatim to the container. Escape hatch for anything not exposed above; container env wins over envFrom, so an entry here overrides the ConfigMap value of the same name. |
| externalSecrets.enabled | bool | false | |
| externalSecrets.secretKey | string | "" | Key/path of this module's secret in the external backend; every key becomes an env var. Defaults to the release fullname. |
| externalSecrets.storeName | string | "local-kubernetes-store" | |
| extraConfigChecksums | list | ["configmap-routes","configmap-static-policies"] | Roll the ACS whenever the generated routes / static-route ConfigMaps change (checksum/config already covers configmap.yaml; these are the extra dynamically generated ConfigMaps this chart mounts). |
| fullnameOverride | string | "authgateway" | Fixed resource-name prefix (instead of the default "-authgateway") so module charts can reference the shared middlewares by a stable name regardless of release name. Also fixes the name of this chart's own Deployment/Service, which is why authGateway.serviceName below must match this value. |
| image | object | {"digest":"sha256:7d21a30932242c4984cdcaafa7bc73b9492c6bff4f3e06c74ea603c99373a2ee","pullPolicy":"IfNotPresent","repository":"labs64/authgateway-traefik","tag":""} | This sets the container image more information can be found here: https://kubernetes.io/docs/concepts/containers/images/ |
| image.digest | string | "sha256:7d21a30932242c4984cdcaafa7bc73b9492c6bff4f3e06c74ea603c99373a2ee" | Pin the image by digest (sha256:<64 hex>). Takes precedence over tag — the release pipeline sets it so a deployment cannot follow a moved tag. |
| image.pullPolicy | string | "IfNotPresent" | This sets the pull policy for images. |
| image.tag | string | "" | Overrides the image tag whose default is the chart appVersion. |
| imagePullSecrets | list | [] | This is for the secrets for pulling an image from a private repository more information can be found here: https://kubernetes.io/docs/tasks/configure-pod-container/pull-image-private-registry/ |
| lifecycle.preStopDrainSeconds | int | 5 | preStop sleep (seconds) so Traefik/kube-proxy deregister the pod before shutdown; 0 disables |
| livenessProbe | object | {"failureThreshold":3,"httpGet":{"path":"/health","port":8081},"initialDelaySeconds":0,"periodSeconds":10,"timeoutSeconds":2} | This is to setup the liveness probes more information can be found here: https://kubernetes.io/docs/tasks/configure-pod-container/configure-liveness-readiness-startup-probes/ |
| logLevel | string | "INFO" | Log level for the Auth Gateway. |
| nameOverride | string | "" | This is to override the chart name. |
| networkPolicy | object | {"egress":[{"ports":[{"port":3592,"protocol":"TCP"}],"to":[{"podSelector":{"matchLabels":{"app.kubernetes.io/name":"authz-pdp"}}}]}],"enabled":false,"extraIngress":[],"extraIngressFrom":[],"gatewayNamespace":"tools","ingressControllerLabels":{},"ingressFrom":null,"ingressPorts":[],"observabilityNamespace":"monitoring","toolsEgress":[{"name":"mock-oidc","port":8080}]} | NetworkPolicy: allow ingress from Traefik and same-namespace pods only (rendered by chart-libs.networkpolicy) |
| networkPolicy.egress | list | [{"ports":[{"port":3592,"protocol":"TCP"}],"to":[{"podSelector":{"matchLabels":{"app.kubernetes.io/name":"authz-pdp"}}}]}] | Egress rules enforcing database-per-service isolation. |
| networkPolicy.extraIngress | list | [] | Additional raw ingress rules |
| networkPolicy.extraIngressFrom | list | [] | Deployment-owned callers appended to ingressFrom without restating it (the umbrella chart adds its own helm test pod here). @schema type: array items: type: string @schema |
| networkPolicy.gatewayNamespace | string | "tools" | Namespace where Traefik runs |
| networkPolicy.ingressControllerLabels | object | {} | Ingress controller pod-selector labels; defaults to the internal Traefik standard (app.kubernetes.io/name: traefik) when empty @schema type: object additionalProperties: true @schema |
| networkPolicy.ingressFrom | string | nil | In-namespace workloads (app.kubernetes.io/name) allowed to call the ports, besides the ingress controller and this chart's own pods (helm test). [] admits no other caller; null (the default) keeps the namespace-wide rule. @schema type: [array, "null"] items: type: string @schema |
| networkPolicy.ingressPorts | list | [] | TCP ports open to the ingress controller and the in-namespace callers in ingressFrom. Empty: every port. Set in overrides/authgateway/values.local.yaml: on AWS this chart's policy is not enabled, and a chart that narrows its ingress in its defaults must be excluded from the deployment repository's fallback rules (kubernetes/network-policies/labs64io.yaml). |
| networkPolicy.observabilityNamespace | string | "monitoring" | Namespace the observability/OTel collector runs in |
| networkPolicy.toolsEgress | list | [{"name":"mock-oidc","port":8080}] | Tools-namespace destinations this service needs (name + port pairs); rendered as scoped egress rules — NOT a blanket allow to the whole tools namespace — to preserve database-per-service isolation. |
| nodeSelector | object | {} | |
| observability | object | {"enabled":false,"metricsScrape":false,"otlpEndpoint":"http://$(NODE_IP):4318"} | Observability is infrastructure-owned: the same image runs with or without it. When enabled, the image's opentelemetry-instrument entrypoint auto-instruments FastAPI (traces + correlated logs + metrics via OTLP). |
| observability.enabled | bool | false | Enable runtime auto-instrumentation (traces + logs + metrics via OTLP) |
| observability.metricsScrape | bool | false | Emit prometheus.io/* scrape annotations. Disabled here: the Auth Gateway is a FastAPI service that pushes metrics over OTLP and serves no Prometheus endpoint (its only routes are /health, /health/ready, /reload and /auth). With this on, the collector scraped /actuator/prometheus on the service port and logged a 404 every interval. |
| observability.otlpEndpoint | string | "http://$(NODE_IP):4318" | OTLP endpoint of the OpenTelemetry Collector |
| oidc | object | {"audience":"account","discoveryUrl":"http://keycloak-http.tools.svc.cluster.local/realms/labs64io/.well-known/openid-configuration","issuer":"","scopesClaimPaths":"scope,realm_access.roles,resource_access.{audience}.roles","tenantClaimPath":"tenant"} | OIDC provider settings. Rendered into this chart's ConfigMap and delivered via envFrom, as scalars rather than a raw env list: Helm replaces lists wholesale on merge, so with a list a caller overriding one field had to restate all eight — and silently lost any entry added upstream later. |
| oidc.audience | string | "account" | Expected JWT audience. |
| oidc.discoveryUrl | string | "http://keycloak-http.tools.svc.cluster.local/realms/labs64io/.well-known/openid-configuration" | Discovery URL (in-cluster transport; the token issuer is oidc.issuer). Defaults to the upstream codecentric/keycloakx release keycloak in the tools namespace (Service keycloak-http). keycloak: http://keycloak-http.tools.svc.cluster.local/realms/labs64io/.well-known/openid-configuration demo/dev: http://mock-oidc..svc.cluster.local:8080/labs64io/.well-known/openid-configuration |
| oidc.issuer | string | "" | Canonical JWT issuer. Set this when discovery uses an internal service URL while tokens carry a public issuer; empty falls back to discovery metadata. |
| oidc.scopesClaimPaths | string | "scope,realm_access.roles,resource_access.{audience}.roles" | Dot-paths (comma-separated) to collect scopes from the JWT; "{audience}" expands to oidc.audience. |
| oidc.tenantClaimPath | string | "tenant" | Dot-path to the tenant claim for X-Auth-Tenant; "-" is emitted when absent. |
| podAnnotations | object | {} | This is for setting Kubernetes Annotations to a Pod. For more information checkout: https://kubernetes.io/docs/concepts/overview/working-with-objects/annotations/ |
| podDisruptionBudget | object | {"enabled":true,"minAvailable":1} | PodDisruptionBudget (rendered by chart-libs.pdb) |
| podLabels | object | {} | This is for setting Kubernetes Labels to a Pod. For more information checkout: https://kubernetes.io/docs/concepts/overview/working-with-objects/labels/ |
| podSecurityContext | object | {} | |
| rateLimit | object | {"average":100,"burst":50,"global":false,"perUser":true} | Rate limit middleware configuration |
| rateLimit.average | int | 100 | Average requests per second |
| rateLimit.burst | int | 50 | Burst size |
| rateLimit.global | bool | false | One bucket per request host instead of per user: a fixed ceiling on the gateway's total ingress, identical for every caller, with per-tenant limits left to the services. Overrides perUser. Traefik keeps buckets in memory, so the ceiling applies per Traefik replica. |
| rateLimit.perUser | bool | true | Rate-limit per authenticated user (X-Auth-User header set by the auth middleware); falls back to per-IP when absent |
| readinessProbe | object | {"failureThreshold":3,"httpGet":{"path":"/health/ready","port":8081},"initialDelaySeconds":0,"periodSeconds":5,"timeoutSeconds":2} | This i |
Deploy authgateway with OpenTenant
Each tenant gets its own release of this chart, with its own namespace, secrets and domain. The builder below already has authgateway 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 chartauthgateway is pinned at v0.15.21 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