Traefik dashboard connection refused

Hi All,

Really struggling to get access to the dashboard. I have deployed traefik within rancher in the system namespace.

It is running, but I cannot for the life of me figure out why the dashboard returns this error

traefik.toml

apiVersion: v1
data:
  traefik.toml: |
    # traefik.toml
    logLevel = "info"
    defaultEntryPoints = ["http","https"]
    [entryPoints]
      [entryPoints.http]
      address = ":80"
      compress = true
      [entryPoints.https]
      address = ":443"
      compress = true
        [entryPoints.https.tls]
          [[entryPoints.https.tls.certificates]]
          CertFile = "/ssl/tls.crt"
          KeyFile = "/ssl/tls.key"
      [entryPoints.traefik]
      address = ":8080"
    [ping]
    entryPoint = "http"
    [kubernetes]
    [traefikLog]
      format = "json"
    [acme]
    KeyType = "RSA4096"
    email = "xxxx@yyyy.com"
    storage = "/acme/acme.json"
    entryPoint = "https"
    onHostRule = true
    caServer = "https://acme-staging-v02.api.letsencrypt.org/directory"
    acmeLogging = true
      [acme.dnsChallenge]
      provider = "duckdns"
    [api]
      entryPoint = "traefik"
      dashboard = true
      insecure = true
kind: ConfigMap
metadata:
  creationTimestamp: "2020-11-30T17:12:25Z"
  labels:
    app: traefik
    chart: traefik-1.0.0
    heritage: Tiller
    io.cattle.field/appId: traefik
    release: traefik
  managedFields:
  - apiVersion: v1
    fieldsType: FieldsV1
    fieldsV1:
      f:data: {}
      f:metadata:
        f:labels:
          .: {}
          f:app: {}
          f:chart: {}
          f:heritage: {}
          f:io.cattle.field/appId: {}
          f:release: {}
    manager: Go-http-client
    operation: Update
    time: "2020-11-30T17:13:23Z"
  - apiVersion: v1
    fieldsType: FieldsV1
    fieldsV1:
      f:data:
        f:traefik.toml: {}
    manager: Mozilla
    operation: Update
    time: "2020-12-01T11:20:56Z"
  name: traefik
  namespace: kube-system
  resourceVersion: "1057880"
  selfLink: /api/v1/namespaces/kube-system/configmaps/traefik
  uid: 7d4248e6-3e70-4210-843b-981813c37e5a

Dashboard.yaml

apiVersion: v1
kind: Service
metadata:
  creationTimestamp: "2020-11-30T17:12:27Z"
  labels:
    app: traefik
    chart: traefik-1.0.0
    heritage: Tiller
    io.cattle.field/appId: traefik
    release: traefik
  managedFields:
  - apiVersion: v1
    fieldsType: FieldsV1
    fieldsV1:
      f:metadata:
        f:labels:
          .: {}
          f:app: {}
          f:chart: {}
          f:heritage: {}
          f:io.cattle.field/appId: {}
          f:release: {}
      f:spec:
        f:ports:
          .: {}
          k:{"port":80,"protocol":"TCP"}:
            .: {}
            f:port: {}
            f:protocol: {}
            f:targetPort: {}
        f:selector:
          .: {}
          f:app: {}
          f:release: {}
        f:sessionAffinity: {}
        f:type: {}
    manager: Go-http-client
    operation: Update
    time: "2020-11-30T17:12:26Z"
  - apiVersion: v1
    fieldsType: FieldsV1
    fieldsV1:
      f:spec:
        f:ports:
          k:{"port":80,"protocol":"TCP"}:
            f:name: {}
    manager: Mozilla
    operation: Update
    time: "2020-12-01T10:22:50Z"
  name: traefik-dashboard
  namespace: kube-system
  resourceVersion: "1048465"
  selfLink: /api/v1/namespaces/kube-system/services/traefik-dashboard
  uid: 479846dd-b3ea-48e6-89e4-645ccfa27210
spec:
  clusterIP: xxxxxxxxxxxx
  ports:
  - name: dashboard-http
    port: 80
    protocol: TCP
    targetPort: 8080
  selector:
    app: traefik
    release: traefik
  sessionAffinity: None
  type: ClusterIP
status:
  loadBalancer: {}

Can anyone see anything stupid? or any suggestions on how I troubleshoot? I am completely new to this and followed a guide on Technotim youtube "Self-Hosting Your Homelab Services with SSL". However he doesn't mention what to do if the dashboard doesn't show

Thanks

What is the error?

When using api insecure traefik will automatically create an entrypoint. Try removing the traefik entrypoint is my advice.

Hi, thank you for your response, i have tried both with and without the api insecure. I get a 404 error on both occasions.

here you can see the localhost refused

localhost

here I can see that the port is being exposed, but I cant access it

I think that / should work but could you also try as per the Quickstart guide http://localhost/api/rawdata

I am reading your file right that you have a port publish of 80 to 8080 ?

Hi

yes that's correct.

Have resolved the issue now. The problem was that I didnt have a dns record in the host file of the machine I was using to access the dashboard. I had put my dns record on the server.

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