<p>I am running Traefik (<strong>v2.0</strong>) as ingress gateway for my EKS cluster. Traefik ingress is working fine.<br />
Now, I need to add https support for my ingress using self signed certificate. For this, I have:</p>
<ul>
<li>Created a IngressRoute from http to https redirectio -&gt; This works fine</li>
<li>Created a secret having the key and cert of my self-signed certificate</li>
</ul>
<blockquote>
<pre><code>kubectl create secret tls tlssecret --key=&quot;eks.tls.key&quot; --cert=&quot;eks.tls.crt&quot;
</code></pre>
</blockquote>
<ul>
<li>Added tls secret to my IngressRoute deployment:</li>
<li>apiVersion: traefik.containo.us/v1alpha1
kind: IngressRoute
metadata:
name: pulseingressroutetls
namespace: pulse
spec:
entryPoints:
- websecure
tls:
secretName: pulsetlssecret<br />
routes:
- match: PathPrefix(<code>/auth</code>)
...</li>
</ul>
<p>After this deployment, when I browse ingress url, it still presents me the TRAEFIK DEFAULT CERT, not my self-signed certificate.</p>
<p>Please let me know what I am doing wrong here? Is there any other way of doing it?</p>

<p>Finally it worked out as below:</p>
<p>traefik-conf.yml:</p>
<pre><code>apiVersion: v1
kind: ConfigMap
metadata:
  name: traefik-conf
  namespace: pulse
data:
  traefik.yml: |
    api:
      dashboard: true
      insecure: true
    global:
      checkNewVersion: false
      sendAnonymousUsage: false
    ping: {}
    entryPoints:
      websecure:
        address: &quot;:443&quot;
      web:
        address: &quot;:80&quot;
    providers:
      kubernetesCRD: {}
      file:
        filename: /etc/traefik/traefik.yml
        watch: true
    tls:
      stores:
        default:
          defaultCertificate:
            certFile: /ssl/tls.pem
            keyFile: /ssl/tls.key
      options:
        default:
          minVersion: VersionTLS12
          sniStrict: false
      certificates:
        - certFile: /ssl/tls.pem
          keyFile: /ssl/tls.key
</code></pre>
<p>I changed ingress controller as below:</p>
<pre><code>spec:
      serviceAccountName: traefik-ingress-controller
      containers:
        - name: traefik
          image: traefik:v2.0
          volumeMounts:
            - name: config
              mountPath: /etc/traefik/traefik.yml
              subPath: traefik.yml
            - name: ssl
              mountPath: /ssl           
          ports:
            - name: web
              containerPort: 80
            - name: websecure
              containerPort: 443
            - name: admin
              containerPort: 8080
      volumes:
      - name: ssl
        secret:
          secretName: traefik-cert
      - name: config
        configMap:
          name: traefik-conf
</code></pre>
<p>Ingress routes:</p>
<pre><code>apiVersion: traefik.containo.us/v1alpha1
kind: IngressRoute
metadata:
  name: pulseingressroutetls
  namespace: pulse
spec:
  entryPoints:
    - websecure 
  tls:
    secretname: traefik-cert
  routes:
...
</code></pre>
