Skip to main content

Gateway API Development Guide

This guide documents the usage of Gateway API manifests for testing and development. These manifests are configured to work with the Envoy Gateway controller (gateway.envoyproxy.io/gatewayclass-controller), and are useful for validating Gateway API features like HTTP routing, gRPC, backend TLS, traffic policies, and cross-namespace permissions.

Manifest Files

FileDescription
gatewayclass.yamlDefines the GatewayClass used by Gateway.
gateway.yamlConfigures the Gateway resource.
httproute.yamlConfigures HTTP route rules.
grpcroute.yamlConfigures gRPC route rules.
referencegrant.yamlGrants cross-namespace access.
backendtls.yamlConfigures TLS for backends.
backendtraffic.yamlConfigures traffic policies to backends.

These files are located in:
frontend/src/components/gateway/manifests/

How to Apply the Manifests

kubectl apply -f frontend/src/components/gateway/manifests/gatewayclass.yaml
kubectl apply -f frontend/src/components/gateway/manifests/gateway.yaml
kubectl apply -f frontend/src/components/gateway/manifests/referencegrant.yaml
kubectl apply -f frontend/src/components/gateway/manifests/httproute.yaml
kubectl apply -f frontend/src/components/gateway/manifests/grpcroute.yaml
kubectl apply -f frontend/src/components/gateway/manifests/backendtls.yaml
kubectl apply -f frontend/src/components/gateway/manifests/backendtraffic.yaml

Alternative: Apply All Manifests at Once

kubectl apply -R -f frontend/src/components/gateway/manifests/

This recursively applies all YAML files in the directory.

Verifying the Setup

After applying the manifests, verify that the Gateway and Routes are accepted and functioning:

kubectl get gateway
kubectl get gatewayclass
kubectl get httproute
kubectl get grpcroute
kubectl describe gateway envoy-gateway
kubectl get backendtlspolicies.gateway.networking.k8s.io
kubectl get xbackendtrafficpolicies.gateway.networking.x-k8s.io

You can also inspect events or logs for the Envoy Gateway controller if routes are not becoming Accepted.

Testing Locally with Minikube

Start a fresh Minikube cluster with a dedicated profile:

minikube start --profile=gateway-checkup

Install the Gateway API CRDs and the Envoy Gateway controller, then apply the manifests as shown above.

Resources