traefik icon indicating copy to clipboard operation
traefik copied to clipboard

Add ingressClassName field to the CRDs spec

Open kkrypt0nn opened this issue 1 month ago • 1 comments

What does this PR do?

This PR adds the ingressClassName field to the CRDs spec. The kubernetes.io/ingress.class annotation is still supported, with a warning being logged to not use it anymore.

Motivation

The issue #11486, as well as the annotation kubernetes.io/ingress.class itself being deprecated/never formally defined.

More

  • [X] Added/updated tests
  • [ ] Added/updated documentation

Additional Notes

I've seen that some things are generated for the documentation, hence I haven't updated the documentation yet. I've also wondered if, for the CRDs documentation I should make it number 2/19 (and edit the others) or add it at the bottom as 28.

I am also unable to use the make generate-crd command due to the following error:

# golang.org/x/tools/internal/tokeninternal
../../../go/pkg/mod/golang.org/x/[email protected]/internal/tokeninternal/tokeninternal.go:78:9: invalid array length -delta * delta (constant -256 of type int64)
make: *** [generate-crd] Error 

Not sure if that blocks the generation of something needed.

kkrypt0nn avatar Nov 24 '25 20:11 kkrypt0nn

Hey @kkrypt0nn,

Thanks for the contribution!

We've set this to "review" and will take a look at the code. We'll update you once the review is done.

nmengin avatar Nov 27 '25 13:11 nmengin