<p>I deployed a helm chart (<code>helm install --name=my-release stable/kube-ops-view</code>) which created a svc with clusterIP, I tried to create a route to it via traefik ingress, but its not working</p>

<p>I have been able to route other applications (nginx) using similar ingress configurations</p>

<pre><code>apiVersion: extensions/v1beta1
kind: Ingress
metadata:
  name: demo-ingress
  namespace: kube-ops-view #svc is created in this namespace
spec:
  rules:
  - host:
    http:
      paths:
      - path: /kube
        backend:
          serviceName: kube-ops-view
          servicePort: 80
</code></pre>

<p>Ingress should have worked</p>

<p>I was able to make it work on GKE cluster.
After cluster creation :</p>

<p>1) Installed Helm</p>

<p>2) Installed NGINX Ingress Controller](<a href="https://kubernetes.github.io/ingress-nginx/deploy/" rel="nofollow noreferrer">https://kubernetes.github.io/ingress-nginx/deploy/</a>) </p>

<p>Next..
You should use <a href="https://kubernetes.github.io/ingress-nginx/examples/rewrite/#rewrite-target" rel="nofollow noreferrer">Rewrite target</a> with <code>nginx.ingress.kubernetes.io/rewrite-target</code> <a href="https://kubernetes.github.io/ingress-nginx/user-guide/nginx-configuration/annotations/" rel="nofollow noreferrer">annotation</a>.</p>

<blockquote>
  <p>Starting in Version 0.22.0, ingress definitions using the annotation
  nginx.ingress.kubernetes.io/rewrite-target are not backwards
  compatible with previous versions. In Version 0.22.0 and beyond, any
  substrings within the request URI that need to be passed to the
  rewritten path must explicitly be defined in a capture group.</p>
</blockquote>

<p>you ingress should look like</p>

<pre><code>apiVersion: extensions/v1beta1
kind: Ingress
metadata:
  annotations:
    kubernetes.io/ingress.class: nginx
    nginx.ingress.kubernetes.io/rewrite-target: /$2
  name: kubeops-kube-ops-view
  namespace: default
spec:
  rules:
  - http:
      paths:
      - backend:
          serviceName: kubeops-kube-ops-view
          servicePort: 80
        path: /kube(/?|$)(.*)
</code></pre>

<p>And another option: you can enable ingress in helm chart without writing ingress yaml.</p>

<p>My way:</p>

<pre><code>helm fetch stable/kube-ops-view --untar
</code></pre>

<p>edit values.yaml</p>

<pre><code>ingress:
  enabled: true
  path: /kube(/|$)(.*)
# hostname: kube-ops-view.local
  annotations: {
    kubernetes.io/ingress.class: nginx,
    nginx.ingress.kubernetes.io/rewrite-target: /$2
  }
  tls: []
  ## Secrets must be manually created in the namespace
  #   - secretName: kube-ops-view.local-tls
  #     hosts:
  #       - kube-ops-view.local
</code></pre>

<p>edit templates/ingress.yaml</p>

<pre><code>{{- if .Values.ingress.enabled -}}
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
  name: {{ template "kube-ops-view.fullname" . }}
  labels:
    app: {{ template "kube-ops-view.fullname" . }}
    chart: "{{ .Chart.Name }}-{{ .Chart.Version }}"
    release: "{{ .Release.Name }}"
    heritage: "{{ .Release.Service }}"
{{- if .Values.ingress.annotations }}
  annotations:
{{ toYaml .Values.ingress.annotations | indent 4 }}
{{- end }}
spec:
  rules:
    - host:
      http:
        paths:
          - path: {{ .Values.ingress.path }}
            backend:
              serviceName: {{ template "kube-ops-view.fullname" . }}
              servicePort: {{ .Values.service.externalPort }}
{{- if .Values.ingress.tls }}
  tls:
{{ toYaml .Values.ingress.tls | indent 4 }}
{{- end -}}
{{- end -}}
</code></pre>

<p>Verify and install:
helm install --server-dry-run --debug  kube-ops-view
helm install kube-ops-view --name kubeops</p>

<p>Check Result:</p>

<pre><code>curl -iLk http://Ingress-external-ip/kube/
HTTP/1.1 308 Permanent Redirect
Server: openresty/1.15.8.1
Date: Thu, 22 Aug 2019 09:21:21 GMT
Content-Type: text/html
Content-Length: 177
Connection: keep-alive
Location: https://Ingress-external-ip/kube/

HTTP/2 200 
server: openresty/1.15.8.1
date: Thu, 22 Aug 2019 09:21:21 GMT
content-type: text/html; charset=utf-8
content-length: 1276
vary: Accept-Encoding
strict-transport-security: max-age=15724800; includeSubDomains

&lt;!doctype html&gt;
&lt;html&gt;
    &lt;head&gt;
        &lt;meta charset="utf-8"&gt;
        &lt;meta name="viewport" content="width=device-width, initial-scale=1"&gt;
        &lt;title&gt;Kubernetes Operational View 0.11&lt;/title&gt;
        &lt;link rel="shortcut icon" href="static/favicon.ico"&gt;
&lt;style&gt;* {padding: 0; margin: 0} body { color: #aaaaff; background: #000; }&lt;/style&gt;
&lt;style&gt;
/* latin */
@font-face {
  font-family: 'ShareTechMono';
  font-style: normal;
  font-weight: 400;
  /* ShareTechMono-Regular.ttf: Copyright (c) 2012, Carrois Type Design, Ralph du Carrois (www.carrois.com post@carrois.com), with Reserved Font Name 'Share'
     License: SIL Open Font License, 1.1 */
  src: local('Share Tech Mono'), local('ShareTechMono-Regular'), url(static/sharetechmono.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2212, U+2215, U+E0FF, U+EFFD, U+F000;
}
&lt;/style&gt;
    &lt;/head&gt;
    &lt;body&gt;
        &lt;!-- make sure the font is loaded --&gt;
        &lt;div id="loading" style="font-family: ShareTechMono"&gt;Loading..&lt;/div&gt;
        &lt;script src="static/build/app-ee71ac795470b05e7f76.js"&gt;&lt;/script&gt;
        &lt;script&gt;document.getElementById('loading').style.display = 'none'; const app = new App(); app.run()&lt;/script&gt;
    &lt;/body&gt;
&lt;/html&gt;
</code></pre>

<p><a href="https://i.stack.imgur.com/FN6ui.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/FN6ui.png" alt="enter image description here"></a></p>
