<h2>Introduction</h2>
<p>Configuring a new ingress-controller with Traefik using helm chart and creating secrets.</p>
<h2>Info</h2>
<p>Kubernetes version: 1.9.3</p>
<p>Helm version: 2.9</p>
<p>Traefik chart version: 1.5</p>
<p>Traefik version: 1.7.2</p>
<h2>Problem</h2>
<p>I am deploying Traefik through official helm chart, but always I have the same problem in the logs
<code>&quot;Error configuring TLS for ingress default/traefik-testing-tls: secret default/traefik-tls does not exist&quot;</code></p>
<p>I have the secret properly created and configured in the same namespace and also checked the clusterrole and clusterrolebinds are ok and allows the access to secrets</p>
<p>I tried to change the <code>defaultCert</code> and <code>defaultKey</code> but not sure about this.</p>
<h3>Configmap:</h3>
<pre><code>data:
traefik.toml: |
# traefik.toml
logLevel = &quot;INFO&quot;
defaultEntryPoints = [&quot;http&quot;, &quot;https&quot;, &quot;httpn&quot;]
[entryPoints]
  [entryPoints.http]
  address = &quot;:80&quot;
  compress = true
  [entryPoints.https]
  address = &quot;:443&quot;
  compress = true
  [entryPoints.httpn]
  address = &quot;:8880&quot;
  compress = true
[kubernetes]
namespaces = [&quot;default&quot;, &quot;kube-system&quot;]
[traefikLog]
  format = &quot;json&quot;
[accessLog]
  format = &quot;common&quot;
[accessLog.fields]
  defaultMode = &quot;keep&quot;
[accessLog.fields.names]
[accessLog.fields.headers]
  defaultMode = &quot;keep&quot;
[accessLog.fields.headers.names]
</code></pre>

<p>Looks like you are missing the <code>traefik-tls</code> secret, for your <code>traefik-testing-tls</code> ingress, that probably holds your TLS certificates. You can follow <a href="https://docs.traefik.io/user-guide/kubernetes/#add-a-tls-certificate-to-the-ingress" rel="nofollow noreferrer">this</a>.</p>

<p>Instead of:</p>

<pre><code>kubectl -n kube-system create secret tls traefik-ui-tls-cert --key=tls.key --cert=tls.crt
</code></pre>

<p>You can use:</p>

<pre><code>kubectl -n kube-system create secret tls traefik-tls --key=tls.key --cert=tls.crt
</code></pre>
