Skip to content

rke2-ingress-nginx deployed with watchIngressWithoutClass: false in v1.27.16+rke2r1, v1.28.12+rke2r1, v1.29.7+rke2r1 and v1.30.3+rke2r1

This document (000021666) is provided subject to the disclaimer at the end of this document.

Environment

An RKE2 cluster running v1.27.16+rke2r1, v1.28.12+rke2r1, v1.29.7+rke2r1 or v1.30.3+rke2r1, which was upgraded from an earlier version.

Situation

After an RKE2 upgrade to version v1.27.16+rke2r1, v1.28.12+rke2r1, v1.29.7+rke2r1 or v1.30.3+rke2r1, ingress-nginx will stop watching any ingress resources that do not define spec.ingressClassName: nginx. Newly created ingress resources that do not define an ingressClassName will have this value set by default. However, any existing ingress objects that were created without an ingressClassName will not be watched by ingress-nginx and traffic will not be routed to them.

Resolution

A fix is available via the rke2-ingress-nginx chart in RKE2 v1.27.16+rke2r2, v1.28.13+rke2r1, v1.29.8+rke2r1, v1.30.4+rke2r1 and above. In these versions, ingress-nginx is deployed with ' --watch-ingress-without-class=true' by default, to ensure traffic continues to be routed to existing ingress resources without an ingressClassName. Users are encouraged to upgrade to take advantage of this fix.

For the affected RKE2 versions, three possible workarounds exist:

  1. Delete and recreate affected ingress objects, so the default ingressClassName of nginx is applied
  2. Update affected ingress resources to set spec.ingressClassName: nginx manually
  3. ` Customise the rke2-ingress-nginx helm chart values, [via a HelmChartConfig resource](https://docs.rke2.io/helm#customizing-packaged-components-with-helmchartconfig), to setwatchIngressWithoutClass: true`

Cause

The rke2-ingress-nginx chart version 4.10.102, bundled with the affected RKE2 versions, is deployed with --watch-ingress-without-class=false. As a result, ingress resources created on older RKE2 versions, in which there was no default ingressClassName, and for which the ingressClassName attribute was not explicitly set to nginx, are not watched by ingress-nginx.

Disclaimer

This Support Knowledgebase provides a valuable tool for SUSE customers and parties interested in our products and solutions to acquire information, ideas and learn from one another. Materials are provided for informational, personal or non-commercial use within your organization and are presented "AS IS" WITHOUT WARRANTY OF ANY KIND.