Skip to content

Commit

Permalink
site: updates for GRPCRoute moving to v1 (#6430)
Browse files Browse the repository at this point in the history
Signed-off-by: Steve Kriss <[email protected]>
  • Loading branch information
skriss authored May 10, 2024
1 parent 9f9547c commit 28a20e8
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
3 changes: 2 additions & 1 deletion site/content/docs/main/config/gateway-api.md
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,8 @@ containers:
- --contour-key-file=/certs/tls.key
- --config-path=/config/contour.yaml
- --disable-feature=tlsroutes
- --disable-feature=grpcroutes
- --disable-feature=tcproutes
...
```

[1]: https://gateway-api.sigs.k8s.io/
Expand Down
10 changes: 5 additions & 5 deletions site/content/docs/main/guides/grpc.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,15 +69,15 @@ metadata:
name: my-grpc-service
spec:
virtualhost:
fqdn: my-grpc-service.foo.com
fqdn: my-grpc-service.foo.com
routes:
- conditions:
- prefix: /yages.Echo/Ping # Matches a specific gRPC method.
services:
- name: grpc-echo
port: 9000
protocol: h2c
- conditions:
- conditions:
- prefix: / # Matches everything else.
services:
- name: grpc-echo
Expand Down Expand Up @@ -144,12 +144,12 @@ spec:

## Gateway API Configuration

Gateway API now supports a specific resource [GRPCRoute][6] for routing gRPC requests.
Gateway API supports a specific resource [GRPCRoute][6] for routing gRPC requests.

Configuring GRPCRoute for routing gRPC requests needs to specify parentRefs, hostnames, and routing rules with specific backendRefs. In the below example, route path matching is conducted via method matching rule for declared services and their methods.

```yaml
apiVersion: gateway.networking.k8s.io/v1alpha2
apiVersion: gateway.networking.k8s.io/v1
kind: GRPCRoute
metadata:
name: yages
Expand Down Expand Up @@ -220,6 +220,6 @@ Piping the output to `base64 -d | od -c` we can see the raw text gRPC response:
[3]: https://github.com/grpc/grpc/blob/master/doc/health-checking.md
[4]: https://github.com/grpc-ecosystem/grpc-health-probe
[5]: https://github.com/fullstorydev/grpcurl
[6]: https://gateway-api.sigs.k8s.io/references/spec/#gateway.networking.k8s.io/v1alpha2.GRPCRoute
[6]: https://gateway-api.sigs.k8s.io/reference/spec/#gateway.networking.k8s.io/v1.GRPCRoute
[7]: https://github.com/grpc/grpc-web
[8]: https://github.com/projectcontour/contour/issues/4290

0 comments on commit 28a20e8

Please sign in to comment.