<p>Hello and thank you for taking the time to read my question.</p>

<p>First, I have an EKS cluster setup to use public and private subnets.</p>

<p>I generated the cluster using cloudformation as described at <a href="https://docs.aws.amazon.com/eks/latest/userguide/getting-started-console.html#vpc-create" rel="nofollow noreferrer">https://docs.aws.amazon.com/eks/latest/userguide/getting-started-console.html#vpc-create</a></p>

<p>I then initialized helm by creating a service account for tiller via <code>kubectl apply -f (below file)</code>:</p>

<pre><code>---
apiVersion: v1
kind: ServiceAccount
metadata:
  name: tiller
  namespace: kube-system
---
apiVersion: rbac.authorization.k8s.io/v1beta1
kind: ClusterRoleBinding
metadata:
  name: tiller
roleRef:
  apiGroup: rbac.authorization.k8s.io
  kind: ClusterRole
  name: cluster-admin
subjects:
  - kind: ServiceAccount
    name: tiller
    namespace: kube-system
</code></pre>

<p>and then <code>helm init --service-account=tiller</code>
followed by <code>helm repo update</code></p>

<p>I then used helm to install the nginx-ingress controller via:</p>

<pre><code>helm install --name nginx-ingress \
        --namespace nginx-project \
        stable/nginx-ingress \
        -f nginx-ingress-values.yaml
</code></pre>

<p>where my nginx-ingress-values.yaml is:</p>

<pre><code>controller:
  service:
    annotations:
      service.beta.kubernetes.io/aws-load-balancer-access-log-emit-interval: "60"
      service.beta.kubernetes.io/aws-load-balancer-access-log-enabled: "true"
      service.beta.kubernetes.io/aws-load-balancer-access-log-s3-bucket-name: "abc-us-west-2-elb-access-logs"
      service.beta.kubernetes.io/aws-load-balancer-access-log-s3-bucket-prefix: "vault-cluster/nginx"
      service.beta.kubernetes.io/aws-load-balancer-ssl-cert: "arn:aws:acm:us-west-2:123456789:certificate/bb35b4c4-..."
      service.beta.kubernetes.io/aws-load-balancer-backend-protocol: "http"
      service.beta.kubernetes.io/aws-load-balancer-ssl-ports: "https"
      service.beta.kubernetes.io/aws-load-balancer-connection-idle-timeout: "60"
</code></pre>

<p>And so far everything looks great, I see the ELB get created and hooked up to use acm for https</p>

<p>I then install kubernetes-dashboard via:</p>

<pre><code>kubectl apply -f https://raw.githubusercontent.com/kubernetes/dashboard/v1.10.1/src/deploy/recommended/kubernetes-dashboard.yaml
</code></pre>

<p>and I can access it via <code>kubectl proxy</code></p>

<p>But when I add an ingress rule for dashboard via:
<code>kubectl apply -f dashboard-ingress.yaml</code>
Where dashboard-ingress.yaml is:</p>

<pre><code>apiVersion: extensions/v1beta1
kind: Ingress
metadata:
  name: dashboard
  annotations:
    nginx.ingress.kubernetes.io/backend-protocol: "HTTPS"
    nginx.ingress.kubernetes.io/force-ssl-redirect: "false"
  namespace: kube-system
spec:
#  tls:
#  - hosts:
#    - abc.def.com
  rules:
  - host: abc.def.com
    http:
      paths:
      - path: /dashboard
        backend:
          serviceName: kubernetes-dashboard
          servicePort: 8443
</code></pre>

<p>then when I try to go <a href="http://abc.def.com/" rel="nofollow noreferrer">http://abc.def.com/</a> I get stuck in an infinite redirect loop.</p>

<p>same for <a href="https://abc.def.com/" rel="nofollow noreferrer">https://abc.def.com/</a>
and
<a href="http://abc.def.com/dashboard" rel="nofollow noreferrer">http://abc.def.com/dashboard</a></p>

<p>I am new to kubernetes and very stuck on this one. Any help would be GREATLY appreciated</p>

<p><strong>UPDATE - 9/5/2019:</strong>
When I take out the tls block from the ingress.yaml I then get</p>

<p>to the nginx backend but <a href="http://abc.def.com" rel="nofollow noreferrer">http://abc.def.com</a> forwards me to <a href="https://abc.def.com" rel="nofollow noreferrer">https://abc.def.com</a> and I get a 502 Bad Gateway from openresty/1.15.8.1</p>

<p>when I then try to go to <a href="https://abc.def.com/dashboard" rel="nofollow noreferrer">https://abc.def.com/dashboard</a></p>

<p>I get "404 page not found" which is a response from the nginx-ingress controller as I understand it.</p>

<p><strong>UPDATE - 9/6/2019:</strong>
Thanks so much to mk_sta for the answer below which helped me understand what I was missing.</p>

<p>For anyone reading this in the future, my nginx-ingress install via helm works as expected but my kubernetes-dashboard install was missing some key annotations. In the end I was able to configure helm to install the kubernetes-dashboard via:</p>

<pre><code>helm install --name kubernetes-dashboard \
    --namespace kube-system \
    stable/kubernetes-dashboard \
    -f kubernetes-dashboard-values.yaml
</code></pre>

<p>where kubernetes-dashboard-values.yaml is:</p>

<pre><code>ingress:
  enabled: true
  hosts: [abc.def.com]
  annotations:
    nginx.ingress.kubernetes.io/backend-protocol: "HTTPS"
    nginx.ingress.kubernetes.io/force-ssl-redirect: "false"
    nginx.ingress.kubernetes.io/rewrite-target: /$2
  paths: [/dashboard(/|$)(.*)]
</code></pre>

<p>I can then access dashboard at <a href="http://abc.def.com/dashboard/" rel="nofollow noreferrer">http://abc.def.com/dashboard/</a> and <a href="https://abc.def.com/dashboard/" rel="nofollow noreferrer">https://abc.def.com/dashboard/</a></p>

<p>For some reason if I leave off the trailing slash it does not work however.</p>

<p>This is good enough for me at the moment.</p>

gh4x
<p>It seems to me that you've used wrong location path <code>/dashboard</code> within yours origin <code>Ingress</code> configuration, even more the relevant <em><a href="https://github.com/kubernetes/dashboard" rel="nofollow noreferrer">K8s dashboard</a> UI</em> endpoint is exposed on <code>443</code> port by default across the corresponded K8s <a href="https://kubernetes.io/docs/concepts/services-networking/service/" rel="nofollow noreferrer">Service</a> resource, whenever you've not customized this setting. </p>

<pre><code>ports:
- port: 443
  protocol: TCP
  targetPort: 8443
</code></pre>

<p>In order to get a proper path based <a href="https://kubernetes.github.io/ingress-nginx/user-guide/basic-usage/" rel="nofollow noreferrer">routing</a>, override existing parameters with the following arguments:</p>

<pre><code>paths:
- path: /
  backend:
    serviceName: kubernetes-dashboard
    servicePort: 443
</code></pre>

<p>Once you've decided accessing <em>K8s dashboard UI</em> through indirect path holder URL (<em><a href="https://abc.def.com/dashboard" rel="nofollow noreferrer">https://abc.def.com/dashboard</a></em>), you can manage applying <a href="https://en.wikipedia.org/wiki/Rewrite_engine" rel="nofollow noreferrer">Rewrite</a> rules in order to transparently change a part of the authentic URL and transmit requests to the faithful target path. Actually, <em><a href="https://en.wikipedia.org/wiki/Rewrite_engine" rel="nofollow noreferrer">Nginx</a> Ingress controller</em> adds this functionality via specific <code>nginx.ingress.kubernetes.io/rewrite-target</code> <a href="https://kubernetes.github.io/ingress-nginx/user-guide/nginx-configuration/annotations/#rewrite" rel="nofollow noreferrer">annotation</a>:</p>

<pre><code>apiVersion: extensions/v1beta1
kind: Ingress
metadata:
  name: dashboard
  annotations:
    nginx.ingress.kubernetes.io/backend-protocol: "HTTPS"
    nginx.ingress.kubernetes.io/force-ssl-redirect: "false"
    nginx.ingress.kubernetes.io/rewrite-target: /$2
  namespace: kube-system
spec:
#  tls:
#  - hosts:
#    - abc.def.com
  rules:
  - host: abc.def.com
    http:
      paths:
      - path: /dashboard(/|$)(.*)
        backend:
          serviceName: kubernetes-dashboard
          servicePort: 443
</code></pre>
