Elk stack docker with traefik

Hi

I have elk stack in docker with tls from documentation Running the Elastic Stack on Docker | Getting Started [7.12] | Elastic

I try run this on server with traefik. I add traefik network for kibana container and add labels:

And I have 502 Bad Gateway on this adres. Stack wihout tls is working with this labels.
any ideas why is this happening?

I'm not familiar with Traefik and Docker, but I do use Traefik with Kubernetes. One thing you might want to try is making sure you set the scheme that Kibana uses, as I believe by default, even if you are using an https entrypoint, Traefik will still try to send the connection to an http backend.

Here is a Kubernetes example (it's not a 1-to-1 match, but should help)

---
apiVersion: traefik.containo.us/v1alpha1
kind: IngressRoute
metadata:
  name: kibana-https-ingress
spec:
  entryPoints:
    - websecure
  routes:
    - kind: Rule
      match: KIBANA_MATCH_RULE
      services:
        - kind: Service
          name: KIBANA_SERVICE_NAME
          port: 5601
          passHostHeader: true
          scheme: https #<----- Scheme set here to https (as Kibana is setup to uses https instead of http)
          serversTransport: kibana-server-transport
  tls:
    secretName: kibana-cert
    options:
      name: kibana-tls-options
      namespace: KIBANA_NAMESPACE

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.