Skip to content

Commit

Permalink
kic: add update guide for gateway API 1.2 (#8297)
Browse files Browse the repository at this point in the history
* add update guide for gateway API 1.2

* address comments

* add title of update gateway API

* Apply suggestions from code review

Co-authored-by: Patryk Małek <patryk.malek@konghq.com>

---------

Co-authored-by: Patryk Małek <patryk.malek@konghq.com>
  • Loading branch information
randmonkey and pmalek authored Dec 20, 2024
1 parent 0236260 commit 9e832a2
Showing 1 changed file with 31 additions and 1 deletion.
32 changes: 31 additions & 1 deletion app/_src/kubernetes-ingress-controller/upgrade/kic.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,9 @@ ingressController:
{% if_version gte:3.2.x %}
### Update Gateway API from v1.0 to v1.1
### Update Gateway API
#### From v1.0 to v1.1
Starting from version 3.2, {{ site.kic_product_name }} supports Gateway API version 1.1.
The primary change in Gateway API v1.1 is the promotion of GRPCRoute from v1alpha2 to v1.
Expand Down Expand Up @@ -73,6 +75,34 @@ complete the following steps to upgrade to version v1.1 of the CRD:

{% endif_version %}

{% if_version gte:3.4.x %}

#### From v1.1 to v1.2

Starting from version 3.4, {{ site.kic_product_name }} supports Gateway API version 1.2.
There is a breaking change in gateway API 1.2 to remove the `v1alpha2` version of `GRPCRoute` and `ReferenceGrant`.

If you have been using gateway API v1.1 and {{ site.kic_product_name }} 3.2 and above, and there are no `GRPCRoute` and `ReferenceGrant` resources stored in `v1alpha2` version, you can directly upgrade gateway API from v1.1 to v1.2.
You can use the following script to ensure your `GRPCRoute` and `ReferenceGrant` CRDs are not using `v1alpha2` storage version:

```bash
kubectl get grpcroutes -A -o jsonpath='{.items[*].apiVersion}' | tr ' ' '\n' | sort | uniq -c
kubectl get referencegrants -A -o jsonpath='{.items[*].apiVersion}' | tr ' ' '\n' | sort | uniq -c
```

If the output contains `v1alpha2`, it means that there are `GRPCRoute`s or `ReferenceGrant`s (or both) using `v1alpha2` storage version and you need to update the manifests before upgrading.

Otherwise, upgrade Gateway API and {{ site.kic_product_name }} following these steps:

1. Ensure you are using Gateway API 1.1 (you can upgrade by following the steps in the section above).
2. Ensure your are using {{ site.kic_product_name }} version 3.2 (or above).
3. Update all your `GRPCRoute` manifests to use `v1` instead of `v1alpha2` and your `ReferenceGrant` manifests to use `v1beta1` instead of `v1alpha2`. This can be done by following the [upgrade guide from Gateway API][gateway-api-v12-upgrade-notes].
4. Install the wanted channel of gateway API 1.2.

[gateway-api-v12-upgrade-notes]: https://gateway-api.sigs.k8s.io/guides/?h=v1.2#v12-upgrade-notes

{% endif_version %}

### Upgrade

Run the following command, specifying the old release name, the namespace where
Expand Down

0 comments on commit 9e832a2

Please sign in to comment.