Skip to content

feat: migrate Traefik Ingress to Kubernetes Gateway API (HTTPRoute) #1494

Description

@ixxeL2097

Overview

Migrate from the legacy Kubernetes Ingress API to the Gateway API (HTTPRoute, GRPCRoute, Gateway CRDs), the future-standard networking API that Traefik already supports.

Why

The Ingress API is feature-frozen. Gateway API is the official successor with:

  • Standardized routing across vendors (no more traefik.ingress.kubernetes.io/ annotations)
  • GRPCRoute for native gRPC routing without workarounds
  • HTTPRoute filters for request/response manipulation
  • Per-route timeout, retry, and header policies
  • Split traffic / canary deployments at the routing level
  • Already supported by Traefik v3+

Migration path

# Before (Ingress)
apiVersion: networking.k8s.io/v1
kind: Ingress
metadata:
  annotations:
    traefik.ingress.kubernetes.io/router.entrypoints: websecure
    traefik.ingress.kubernetes.io/router.middlewares: traefik-authentik@kubernetescrd
spec:
  rules:
    - host: app.fredcorp.com
      http:
        paths:
          - path: /
            backend:
              service:
                name: app
                port:
                  number: 80
# After (HTTPRoute)
apiVersion: gateway.networking.k8s.io/v1
kind: HTTPRoute
metadata:
  name: app
spec:
  parentRefs:
    - name: traefik-gateway
      namespace: traefik
  hostnames:
    - app.fredcorp.com
  rules:
    - matches:
        - path:
            type: PathPrefix
            value: /
      backendRefs:
        - name: app
          port: 80

Phases

  1. Enable Gateway API CRDs and Traefik Gateway provider
  2. Create Gateway resources (internal + external)
  3. Migrate apps one by one (non-breaking alongside existing Ingress)
  4. Remove legacy Ingress resources

Notes

Reference

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions