<p>My Kubernetes ingress has the following:</p>
<pre><code>  ingress:
    enabled: true
    annotations: 
      kubernetes.io/ingress.class: alb
      ...
      ...
    # -- Defines which ingress controller will implement the resource
    ingressClassName: &quot;&quot;
</code></pre>
<p>I'm a bit confused about the difference between &quot;kubernetes.io/ingress.class&quot; and &quot;ingressClassName.&quot;.</p>
<p>I believe &quot;kubernetes.io/ingress.class&quot; needs to match the ingressClass as defined in the AWS ALB Ingress Controller.</p>
<p>However, then I'm confused about the role of &quot;ingressClassName&quot;? As that seems to be the same thing.</p>
<p>Any clarity would be appreciated.</p>

sebastianwth
<p>Actually, both refer to the same thing, but <code>kubernetes.io/ingress.class</code> is deprecated from Kubernetes v1.22+. and <code>ingressClassName</code> is introduced in <code>1.18</code>, so if you are using higher version you can <code>ingressClassName</code></p>
<blockquote>
<p>Before the <code>IngressClass</code> resource and <code>ingressClassName</code> field were added in Kubernetes 1.18, Ingress classes were specified with a <code>kubernetes.io/ingress.class</code> annotation on the Ingress. This annotation was never formally defined, but was widely supported by Ingress controllers.</p>
</blockquote>
<blockquote>
<p><strong>The newer <code>ingressClassName</code> field on Ingresses is a replacement for that annotation</strong>, but is not a direct equivalent. While the annotation was generally used to reference the name of the Ingress controller that should implement the Ingress, <strong>the field is a reference to an IngressClass resource that contains additional Ingress configuration</strong>,</p>
</blockquote>
<p><a href="https://kubernetes.io/docs/concepts/services-networking/ingress/#deprecated-annotation" rel="noreferrer">ingress-deprecated-annotation</a></p>
<p>Your example is</p>
<pre><code>  ingress:
    enabled: true
    annotations: 
      kubernetes.io/ingress.class: alb
</code></pre>
<p>its equivalent value is <code>className: &quot;nginx&quot;</code></p>
<pre><code>  ingress:
    enabled: true
    className: &quot;alb&quot; -&gt; ingressClassName
</code></pre>
<p>if you check the <code>ingress</code> template, it will be like this</p>
<pre><code>  ingressClassName: {{ .Values.ingress.className }}
</code></pre>
