Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save carlosedp/91e1c261b27d8b286ab800d52501f112 to your computer and use it in GitHub Desktop.
Save carlosedp/91e1c261b27d8b286ab800d52501f112 to your computer and use it in GitHub Desktop.
apiVersion: v1
kind: ConfigMap
metadata:
name: traefik-conf-external
namespace: kube-system
data:
traefik.toml: |
defaultEntryPoints = ["http","https"]
debug = false
logLevel = "INFO"
#Config to redirect http to https
[entryPoints]
[entryPoints.http]
address = ":80"
compress = true
[entryPoints.http.redirect]
entryPoint = "https"
[entryPoints.https]
address = ":443"
compress = true
[entryPoints.https.tls]
[api]
[api.statistics]
recentErrors = 10
[kubernetes]
# Only create ingresses where the object has traffic-type: external label
labelselector = "traffic-type=external"
[metrics]
[metrics.prometheus]
buckets=[0.1,0.3,1.2,5.0]
entryPoint = "traefik"
[ping]
entryPoint = "http"
[accessLog]
[etcd]
endpoint = "etcd-traefik-store.kube-system:2379"
#watch = true
#prefix = "/traefik-external"
[acme]
email = "email@gmail.com"
storage = "traefik-external/acme/account"
acmeLogging = true
entryPoint = "https"
OnHostRule = true
#caServer = "https://acme-v01.api.letsencrypt.org/directory"
[acme.httpChallenge]
entryPoint="http"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment