doc: improve examples.

This commit is contained in:
Ludovic Fernandez 2019-07-22 09:58:04 +02:00 committed by Traefiker Bot
parent 8b4ba3cb67
commit 75c99a0491
69 changed files with 1256 additions and 552 deletions

View file

@ -9,20 +9,25 @@ Understanding how you use Traefik is very important to us: it helps us improve t
For this very reason, the sendAnonymousUsage option is mandatory: we want you to take time to consider whether or not you wish to share anonymous data with us so we can benefit from your experience and use cases.
!!! warning
During the alpha stage only, leaving this option unset will not prevent Traefik from running but will generate an error log indicating that it enables data collection by default.
During the beta stage only, leaving this option unset will not prevent Traefik from running but will generate an error log indicating that it enables data collection by default.
??? example "Enabling Data Collection with TOML"
!!! example "Enabling Data Collection"
```toml
```toml tab="File (TOML)"
[global]
# Send anonymous usage data
sendAnonymousUsage = true
```
??? example "Enabling Data Collection with the CLI"
```yaml tab="File (YAML)"
global:
# Send anonymous usage data
sendAnonymousUsage: true
```
```bash
./traefik --sendAnonymousUsage=true
```bash tab="CLI"
# Send anonymous usage data
--global.sendAnonymousUsage
```
## Collected Data

View file

@ -8,7 +8,7 @@ You can install Traefik with the following flavors:
## Use the Official Docker Image
Choose one of the [official Docker images](https://hub.docker.com/_/traefik) and run it with the [sample configuration file](https://raw.githubusercontent.com/containous/traefik/master/traefik.sample.toml):
Choose one of the [official Docker images](https://hub.docker.com/_/traefik) and run it with the [sample configuration file](https://raw.githubusercontent.com/containous/traefik/v2.0/traefik.sample.toml):
```shell
docker run -d -p 8080:8080 -p 80:80 \

View file

@ -109,7 +109,7 @@ when using the `TLS-ALPN-01` challenge, Traefik must be reachable by Let's Encry
```bash tab="CLI"
# ...
--certificatesResolvers.sample.acme.tlsChallenge
--certificatesResolvers.sample.acme.tlsChallenge=true
```
### `httpChallenge`

View file

@ -1,5 +1,4 @@
# Enable ACME (Let's Encrypt): automatic SSL.
--certificatesResolvers.sample.acme
# Email address used for registration.
#
@ -35,13 +34,13 @@
#
# Optional (but recommended)
#
--certificatesResolvers.sample.acme.tlsChallenge
--certificatesResolvers.sample.acme.tlsChallenge=true
# Use a HTTP-01 ACME challenge.
#
# Optional
#
--certificatesResolvers.sample.acme.httpChallenge
--certificatesResolvers.sample.acme.httpChallenge=true
# EntryPoint to use for the HTTP-01 challenges.
#
@ -54,7 +53,7 @@
#
# Optional
#
--certificatesResolvers.sample.acme.dnsChallenge
--certificatesResolvers.sample.acme.dnsChallenge=true
# DNS provider used.
#

View file

@ -35,7 +35,7 @@ tls:
!!! important "File Provider Only"
In the above example, we've used the [file provider](../providers/file.md) to handle these definitions.
In its current alpha version, it is the only available method to configure the certificates (as well as the options and the stores).
In its current beta version, it is the only available method to configure the certificates (as well as the options and the stores).
## Certificates Stores
@ -52,9 +52,9 @@ tls:
default: {}
```
!!! important "Alpha restriction"
!!! important "Beta restriction"
During the alpha version, any store definition other than the default one (named `default`) will be ignored,
During the beta version, any store definition other than the default one (named `default`) will be ignored,
and there is thefore only one globally available TLS store.
In the `tls.certificates` section, a list of stores can then be specified to indicate where the certificates should be stored:
@ -85,9 +85,9 @@ tls:
keyFile: /path/to/other-domain.key
```
!!! important "Alpha restriction"
!!! important "Beta restriction"
During the alpha version, the `stores` list will actually be ignored and automatically set to `["default"]`.
During the beta version, the `stores` list will actually be ignored and automatically set to `["default"]`.
### Default Certificate

View file

@ -1,2 +1,2 @@
!!! info "More On Entrypoints"
Learn more about entrypoints and their configuration options in the dedicated section.
!!! info "More On Entry Points"
Learn more about entry points and their configuration options in the dedicated section.

View file

@ -38,13 +38,22 @@ labels:
- "traefik.http.middlewares.add-foo.addprefix.prefix=/foo"
```
```toml tab="File"
```toml tab="File (TOML)"
# Prefixing with /foo
[http.middlewares]
[http.middlewares.add-foo.addPrefix]
prefix = "/foo"
```
```yaml tab="File (YAML)"
# Prefixing with /foo
http:
middlewares:
add-foo:
addPrefix:
prefix: "/foo"
```
## Configuration Options
### `prefix`

View file

@ -44,7 +44,7 @@ labels:
- "traefik.http.middlewares.test-auth.basicauth.users=test:$apr1$H6uskkkW$IgXLP6ewTrSuBkTrqE8wj/,test2:$apr1$d9hr9HBB$4HxwgUir3HP4EsggP/QNo0"
```
```toml tab="File"
```toml tab="File (TOML)"
# Declaring the user list
[http.middlewares]
[http.middlewares.test-auth.basicAuth]
@ -54,6 +54,17 @@ labels:
]
```
```yaml tab="File (YAML)"
# Declaring the user list
http:
middlewares:
test-auth:
basicAuth:
users:
- "test:$apr1$H6uskkkW$IgXLP6ewTrSuBkTrqE8wj/"
- "test2:$apr1$d9hr9HBB$4HxwgUir3HP4EsggP/QNo0"
```
## Configuration Options
### General
@ -119,12 +130,21 @@ spec:
}
```
```toml tab="File"
```toml tab="File (TOML)"
[http.middlewares.my-auth.basicAuth]
# ...
headerField = "X-WebAuth-User"
```
```yaml tab="File (YAML)"
http:
middlewares:
my-auth:
basicAuth:
# ...
headerField: "X-WebAuth-User"
```
### `removeHeader`
Set the `removeHeader` option to `true` to remove the authorization header before forwarding the request to your service. (Default value is `false`.)

View file

@ -42,13 +42,22 @@ labels:
- "traefik.http.middlewares.limit.buffering.maxRequestBodyBytes=250000"
```
```toml tab="File"
```toml tab="File (TOML)"
# Sets the maximum request body to 2Mb
[http.middlewares]
[http.middlewares.limit.buffering]
maxRequestBodyBytes = 250000
```
```yaml tab="File (YAML)"
# Sets the maximum request body to 2Mb
http:
middlewares:
limit:
buffering:
maxRequestBodyBytes: 250000
```
## Configuration Options
### `maxRequestBodyBytes`
@ -77,7 +86,7 @@ You can have the Buffering middleware replay the request with the help of the `r
!!! example "Retries once in case of a network error"
```
```toml
retryExpression = "IsNetworkError() && Attempts() < 2"
```

View file

@ -108,7 +108,7 @@ labels:
- "http.services.service1.loadbalancer.server.port=80"
```
```toml tab="File"
```toml tab="File (TOML)"
# ...
[http.routers]
[http.routers.router1]
@ -135,3 +135,43 @@ labels:
[[http.services.service1.loadBalancer.servers]]
url = "http://127.0.0.1:80"
```
```yaml tab="File (YAML)"
# ...
http:
routers:
router1:
service: service1
middlewares:
- secured
rule: "Host(`mydomain`)"
middlewares:
secured:
chain:
middlewares:
- https-only
- known-ips
- auth-users
auth-users:
basicAuth:
users:
- "test:$apr1$H6uskkkW$IgXLP6ewTrSuBkTrqE8wj/"
https-only:
redirectScheme:
scheme: https
known-ips:
ipWhiteList:
sourceRange:
- "192.168.1.7"
- "127.0.0.1/32"
services:
service1:
loadBalancer:
servers:
- url: "http://127.0.0.1:80"
```

View file

@ -52,13 +52,22 @@ labels:
- "traefik.http.middlewares.latency-check.circuitbreaker.expression=LatencyAtQuantileMS(50.0) > 100"
```
```toml tab="File"
```toml tab="File (TOML)"
# Latency Check
[http.middlewares]
[http.middlewares.latency-check.circuitBreaker]
expression = "LatencyAtQuantileMS(50.0) > 100"
```
```yaml tab="File (YAML)"
# Latency Check
http:
middlewares:
latency-check:
circuitBreaker:
expression: "LatencyAtQuantileMS(50.0) > 100"
```
## Possible States
There are three possible states for your circuit breaker:

View file

@ -37,12 +37,20 @@ labels:
- "traefik.http.middlewares.test-compress.compress=true"
```
```toml tab="File"
```toml tab="File (TOML)"
# Enable gzip compression
[http.middlewares]
[http.middlewares.test-compress.compress]
```
```yaml tab="File (YAML)"
# Enable gzip compression
http:
middlewares:
test-compress:
compress: {}
```
## Notes
Responses are compressed when:

View file

@ -38,7 +38,7 @@ labels:
- "traefik.http.middlewares.test-auth.digestauth.users=test:traefik:a2688e031edb4be6a3797f3882655c05,test2:traefik:518845800f9e2bfb1f1f740ec24f074e"
```
```toml tab="File"
```toml tab="File (TOML)"
[http.middlewares]
[http.middlewares.test-auth.digestAuth]
users = [
@ -47,6 +47,16 @@ labels:
]
```
```yaml tab="File (YAML)"
http:
middlewares:
test-auth:
digestAuth:
users:
- "test:traefik:a2688e031edb4be6a3797f3882655c05"
- "test2:traefik:518845800f9e2bfb1f1f740ec24f074e"
```
!!! tip
Use `htdigest` to generate passwords.
@ -115,12 +125,21 @@ labels:
}
```
```toml tab="File"
```toml tab="File (TOML)"
[http.middlewares.my-auth.digestAuth]
# ...
headerField = "X-WebAuth-User"
```
```yaml tab="File (YAML)"
http:
middlewares:
my-auth:
digestAuth:
# ...
headerField: "X-WebAuth-User"
```
### `removeHeader`
Set the `removeHeader` option to `true` to remove the authorization header before forwarding the request to your service. (Default value is `false`.)

View file

@ -49,7 +49,7 @@ labels:
- "traefik.http.middlewares.test-errorpage.errors.query=/{status}.html"
```
```toml tab="File"
```toml tab="File (TOML)"
# Custom Error Page for 5XX
[http.middlewares]
[http.middlewares.test-errorpage.errors]
@ -61,6 +61,21 @@ labels:
# ... definition of error-handler-service and my-service
```
```yaml tab="File (YAML)"
# Custom Error Page for 5XX
http:
middlewares:
test-errorpage:
errors:
status:
- "500-599"
service: serviceError
query: "/{status}.html"
[http.services]
# ... definition of error-handler-service and my-service
```
!!! note
In this example, the error page URL is based on the status code (`query=/{status}.html)`.

View file

@ -69,7 +69,7 @@ labels:
- "traefik.http.middlewares.test-auth.forwardauth.trustForwardHeader=true"
```
```toml tab="File"
```toml tab="File (TOML)"
# Forward authentication to authserver.com
[http.middlewares]
[http.middlewares.test-auth.forwardAuth]
@ -84,6 +84,24 @@ labels:
key = "path/to/foo.key"
```
```yaml tab="File (YAML)"
# Forward authentication to authserver.com
http:
middlewares:
test-auth:
forwardAuth:
address: "https://authserver.com/auth"
trustForwardHeader: true
authResponseHeaders:
- "X-Auth-User"
- "X-Secret"
tls:
ca: "path/to/local.crt"
caOptional: true
cert: "path/to/foo.cert"
key: "path/to/foo.key"
```
## Configuration Options
### `address`

View file

@ -16,7 +16,7 @@ Add the `X-Script-Name` header to the proxied request and the `X-Custom-Response
```yaml tab="Docker"
labels:
- "traefik.http.middlewares.testHeader.headers.customrequestheaders.X-Script-Name=test"
- "traefik.http.middlewares.testHeader.headers.customresponseheaders.X-Custom-Response-Header=True"
- "traefik.http.middlewares.testHeader.headers.customresponseheaders.X-Custom-Response-Header=value"
```
```yaml tab="Kubernetes"
@ -29,29 +29,40 @@ spec:
customRequestHeaders:
X-Script-Name: "test"
customResponseHeaders:
X-Custom-Response-Header: "True"
X-Custom-Response-Header: "value"
```
```json tab="Marathon"
"labels": {
"traefik.http.middlewares.testheader.headers.customrequestheaders.X-Script-Name": "test",
"traefik.http.middlewares.testheader.headers.customresponseheaders.X-Custom-Response-Header": "True"
"traefik.http.middlewares.testheader.headers.customresponseheaders.X-Custom-Response-Header": "value"
}
```
```yaml tab="Rancher"
labels:
- "traefik.http.middlewares.testheader.headers.customrequestheaders.X-Script-Name=test"
- "traefik.http.middlewares.testheader.headers.customresponseheaders.X-Custom-Response-Header=True"
- "traefik.http.middlewares.testheader.headers.customresponseheaders.X-Custom-Response-Header=value"
```
```toml tab="File"
```toml tab="File (TOML)"
[http.middlewares]
[http.middlewares.testHeader.headers]
[http.middlewares.testHeader.headers.customRequestHeaders]
X-Script-Name = "test"
[http.middlewares.testHeader.headers.customResponseHeaders]
X-Custom-Response-Header = "True"
X-Custom-Response-Header = "value"
```
```yaml tab="File (YAML)"
http:
middlewares:
testHeader:
headers:
customRequestHeaders:
X-Script-Name: "test"
customResponseHeaders:
X-Custom-Response-Header: "value"
```
### Adding and Removing Headers
@ -86,7 +97,7 @@ labels:
}
```
```toml tab="File"
```toml tab="File (TOML)"
[http.middlewares]
[http.middlewares.testHeader.headers]
[http.middlewares.testHeader.headers.customRequestHeaders]
@ -96,6 +107,18 @@ labels:
X-Custom-Response-Header = "" # Removes
```
```yaml tab="File (YAML)"
http:
middlewares:
testHeader:
headers:
customRequestHeaders:
X-Script-Name: "test" # Adds
X-Custom-Request-Header: "" # Removes
customResponseHeaders:
X-Custom-Response-Header: "" # Removes
```
### Using Security Headers
Security related headers (HSTS headers, SSL redirection, Browser XSS filter, etc) can be added and configured per frontend in a similar manner to the custom headers above.
@ -131,13 +154,22 @@ labels:
}
```
```toml tab="File"
```toml tab="File (TOML)"
[http.middlewares]
[http.middlewares.testHeader.headers]
FrameDeny = true
SSLRedirect = true
```
```yaml tab="File (YAML)"
http:
middlewares:
testHeader:
headers:
FrameDeny: true
SSLRedirect: true
```
### CORS Headers
CORS (Cross-Origin Resource Sharing) headers can be added and configured per frontend in a similar manner to the custom headers above.
@ -184,7 +216,7 @@ labels:
}
```
```toml tab="File"
```toml tab="File (TOML)"
[http.middlewares]
[http.middlewares.testHeader.headers]
accessControlAllowMethods= ["GET", "OPTIONS", "PUT"]
@ -193,6 +225,20 @@ labels:
addVaryHeader = true
```
```yaml tab="File (YAML)"
http:
middlewares:
testHeader:
headers:
accessControlAllowMethod:
- GET
- OPTIONS
- PUT
accessControlAllowOrigin: "origin-list-or-null"
accessControlMaxAge: 100
addVaryHeader: true
```
## Configuration Options
### General

View file

@ -39,13 +39,24 @@ labels:
- "traefik.http.middlewares.test-ipwhitelist.ipwhitelist.sourcerange=127.0.0.1/32, 192.168.1.7"
```
```toml tab="File"
```toml tab="File (TOML)"
# Accepts request from defined IP
[http.middlewares]
[http.middlewares.test-ipwhitelist.ipWhiteList]
sourceRange = ["127.0.0.1/32", "192.168.1.7"]
```
```yaml tab="File (YAML)"
# Accepts request from defined IP
http:
middlewares:
test-ipwhitelist:
ipWhiteList:
sourceRange:
- "127.0.0.1/32"
- "192.168.1.7"
```
## Configuration Options
### `sourceRange`
@ -108,7 +119,7 @@ The `depth` option tells Traefik to use the `X-Forwarded-For` header and take th
}
```
```toml tab="File"
```toml tab="File (TOML)"
# Whitelisting Based on `X-Forwarded-For` with `depth=2`
[http.middlewares]
[http.middlewares.test-ipwhitelist.ipWhiteList]
@ -117,6 +128,19 @@ The `depth` option tells Traefik to use the `X-Forwarded-For` header and take th
depth = 2
```
```yaml tab="File (YAML)"
# Whitelisting Based on `X-Forwarded-For` with `depth=2`
http:
middlewares:
test-ipwhitelist:
ipWhiteList:
sourceRange:
- "127.0.0.1/32"
- "192.168.1.7"
ipStrategy:
depth: 2
```
!!! note
- If `depth` is greater than the total number of IPs in `X-Forwarded-For`, then the client IP will be empty.
@ -171,10 +195,22 @@ labels:
}
```
```toml tab="File"
```toml tab="File (TOML)"
# Exclude from `X-Forwarded-For`
[http.middlewares]
[http.middlewares.test-ipwhitelist.ipWhiteList]
[http.middlewares.test-ipwhitelist.ipWhiteList.ipStrategy]
excludedIPs = ["127.0.0.1/32", "192.168.1.7"]
```
```yaml tab="File (YAML)"
# Exclude from `X-Forwarded-For`
http:
middlewares:
test-ipwhitelist:
ipWhiteList:
ipStrategy:
excludedIPs:
- "127.0.0.1/32"
- "192.168.1.7"
```

View file

@ -37,23 +37,32 @@ labels:
- "traefik.http.middlewares.test-maxconn.maxconn.amount=10"
```
```toml tab="File"
```toml tab="File (TOML)"
# Limiting to 10 simultaneous connections
[http.middlewares]
[http.middlewares.test-maxconn.maxConn]
amount = 10
```
```yaml tab="File (YAML)"
# Limiting to 10 simultaneous connections
http:
middlewares:
test-maxconn:
maxConn:
amount: 10
```
## Configuration Options
### `amount`
The `amount` option defines the maximum amount of allowed simultaneous connections.
The middleware will return an `HTTP 429 Too Many Requests` if there are already `amount` requests in progress (based on the same `extractorfunc` strategy).
The middleware will return an `HTTP 429 Too Many Requests` if there are already `amount` requests in progress (based on the same `extractorFunc` strategy).
### extractorfunc
### `extractorFunc`
The `extractorfunc` defines the strategy used to categorize requests.
The `extractorFunc` defines the strategy used to categorize requests.
The possible values are:

View file

@ -79,8 +79,8 @@ labels:
- "traefik.http.router.router1.middlewares=foo-add-prefix@rancher"
```
```toml tab="File"
# As Toml Configuration File
```toml tab="File (TOML)"
# As TOML Configuration File
[http.routers]
[http.routers.router1]
service = "myService"
@ -99,6 +99,28 @@ labels:
url = "http://127.0.0.1:80"
```
```yaml tab="File (YAML)"
# As YAML Configuration File
http:
routers:
router1:
service: myService
middlewares:
- "foo-add-prefix"
rule: "Host(`example.com`)"
middlewares:
foo-add-prefix:
addPrefix:
prefix: "/foo"
services:
service1:
loadBalancer:
servers:
- url: "http://127.0.0.1:80"
```
## Provider Namespace
When you declare a middleware, it lives in its provider namespace.
@ -124,12 +146,20 @@ and therefore this specification would be ignored even if present.
Declaring the add-foo-prefix in the file provider.
```toml
```toml tab="File (TOML)"
[http.middlewares]
[http.middlewares.add-foo-prefix.addPrefix]
prefix = "/foo"
```
```yaml tab="File (YAML)"
http:
middlewares:
add-foo-prefix:
addPrefix:
prefix: "/foo"
```
Using the add-foo-prefix middleware from other providers:
```yaml tab="Docker"

View file

@ -39,13 +39,22 @@ labels:
- "traefik.http.middlewares.test-passtlsclientcert.passtlsclientcert.pem=true"
```
```toml tab="File"
```toml tab="File (TOML)"
# Pass the escaped pem in the `X-Forwarded-Tls-Client-Cert` header.
[http.middlewares]
[http.middlewares.test-passtlsclientcert.passTLSClientCert]
pem = true
```
```yaml tab="File (YAML)"
# Pass the escaped pem in the `X-Forwarded-Tls-Client-Cert` header.
http:
middlewares:
test-passtlsclientcert:
passTLSClientCert:
pem: true
```
??? example "Pass the escaped pem in the `X-Forwarded-Tls-Client-Cert` header"
```yaml tab="Docker"
@ -144,7 +153,7 @@ labels:
}
```
```toml tab="File"
```toml tab="File (TOML)"
# Pass all the available info in the `X-Forwarded-Tls-Client-Cert-Info` header
[http.middlewares]
[http.middlewares.test-passtlsclientcert.passTLSClientCert]
@ -170,6 +179,34 @@ labels:
domainComponent = true
```
```yaml tab="File (YAML)"
# Pass all the available info in the `X-Forwarded-Tls-Client-Cert-Info` header
http:
middlewares:
test-passtlsclientcert:
passTLSClientCert:
info:
notAfter: true
notBefore: true
sans: true
subject:
country: true
province: true
locality: true
organization: true
commonName: true
serialNumber: true
domainComponent: true
issuer:
country: true
province: true
locality: true
organization: true
commonName: true
serialNumber: true
domainComponent: true
```
## Configuration Options
### General

View file

@ -73,12 +73,12 @@ labels:
```
```toml tab="File"
```toml tab="File (TOML)"
# Here, an average of 5 requests every 3 seconds is allowed and an average of 100 requests every 10 seconds.
# These can "burst" up to 10 and 200 in each period, respectively.
[http.middlewares]
[http.middlewares.test-ratelimit.rateLimit]
extractorfunc = "client.ip"
extractorFunc = "client.ip"
[http.middlewares.test-ratelimit.rateLimit.rateSet.rate0]
period = "10s"
@ -91,11 +91,30 @@ labels:
burst = 10
```
```yaml tab="File (YAML)"
# Here, an average of 5 requests every 3 seconds is allowed and an average of 100 requests every 10 seconds.
# These can "burst" up to 10 and 200 in each period, respectively.
http:
middlewares:
test-ratelimit:
rateLimit:
extractorFunc: "client.ip"
rateSet:
rate0:
period: "10s"
average: 100
burst: 200
rate1:
period: "3s"
average: 5
burst: 10
```
## Configuration Options
### `extractorfunc`
### `extractorFunc`
The `extractorfunc` option defines the strategy used to categorize requests.
The `extractorFunc` option defines the strategy used to categorize requests.
The possible values are:

View file

@ -42,7 +42,7 @@ labels:
- "traefik.http.middlewares.test-redirectregex.redirectregex.replacement=http://mydomain/$1"
```
```toml tab="File"
```toml tab="File (TOML)"
# Redirect with domain replacement
[http.middlewares]
[http.middlewares.test-redirectregex.redirectRegex]
@ -50,6 +50,16 @@ labels:
replacement = "http://mydomain/$1"
```
```yaml tab="File (YAML)"
# Redirect with domain replacement
http:
middlewares:
test-redirectregex:
redirectRegex:
regex: "^http://localhost/(.*)"
replacement: "http://mydomain/$1"
```
## Configuration Options
### `permanent`

View file

@ -38,13 +38,22 @@ labels:
- "traefik.http.middlewares.test-redirectscheme.redirectscheme.scheme=https"
```
```toml tab="File"
```toml tab="File (TOML)"
# Redirect to https
[http.middlewares]
[http.middlewares.test-redirectscheme.redirectScheme]
scheme = "https"
```
```yaml tab="File (YAML)"
# Redirect to https
http:
middlewares:
test-redirectscheme:
redirectScheme:
scheme: https
```
## Configuration Options
### `permanent`

View file

@ -38,13 +38,22 @@ labels:
- "traefik.http.middlewares.test-replacepath.replacepath.path=/foo"
```
```toml tab="File"
```toml tab="File (TOML)"
# Replace the path by /foo
[http.middlewares]
[http.middlewares.test-replacepath.replacePath]
path = "/foo"
```
```yaml tab="File (YAML)"
# Replace the path by /foo
http:
middlewares:
test-replacepath:
replacePath:
path: "/foo"
```
## Configuration Options
### General

View file

@ -42,7 +42,7 @@ labels:
- "traefik.http.middlewares.test-replacepathregex.replacepathregex.replacement=/bar/$1"
```
```toml tab="File"
```toml tab="File (TOML)"
# Redirect with domain replacement
[http.middlewares]
[http.middlewares.test-replacepathregex.replacePathRegex]
@ -50,6 +50,16 @@ labels:
replacement = "/bar/$1"
```
```yaml tab="File (YAML)"
# Redirect with domain replacement
http:
middlewares:
test-replacepathregex:
replacePathRegex:
regex: "^/foo/(.*)"
replacement: "/bar/$1"
```
## Configuration Options
### General

View file

@ -38,13 +38,22 @@ labels:
- "traefik.http.middlewares.test-retry.retry.attempts=4"
```
```toml tab="File"
```toml tab="File (TOML)"
# Retry to send request 4 times
[http.middlewares]
[http.middlewares.test-retry.retry]
attempts = 4
```
```yaml tab="File (YAML)"
# Retry to send request 4 times
http:
middlewares:
test-retry:
retry:
attempts: 4
```
## Configuration Options
### `attempts`

View file

@ -40,13 +40,24 @@ labels:
- "traefik.http.middlewares.test-stripprefix.stripprefix.prefixes=/foobar, /fiibar"
```
```toml tab="File"
```toml tab="File (TOML)"
# Strip prefix /foobar and /fiibar
[http.middlewares]
[http.middlewares.test-stripprefix.stripPrefix]
prefixes = ["/foobar", "/fiibar"]
```
```yaml tab="File (YAML)"
# Strip prefix /foobar and /fiibar
http:
middlewares:
test-stripprefix:
stripPrefix:
prefixes:
- "/foobar"
- "/fiibar"
```
## Configuration Options
### General

View file

@ -38,11 +38,20 @@ labels:
- "traefik.http.middlewares.test-stripprefixregex.stripprefixregex.regex=^/foo/(.*)",
```
```toml tab="File"
```toml tab="File (TOML)"
# Replace the path by /foo
[http.middlewares]
[http.middlewares.test-stripprefixregex.stripPrefixRegex]
regex: "^/foo/(.*)"
regex = "^/foo/(.*)"
```
```yaml tab="File (YAML)"
# Replace the path by /foo
http:
middlewares:
test-stripprefixregex:
stripPrefixRegex:
regex: "^/foo/(.*)"
```
## Configuration Options

View file

@ -9,12 +9,16 @@ By default, logs are written to stdout, in text format.
To enable the access logs:
```toml tab="File"
```toml tab="File (TOML)"
[accessLog]
```
```yaml tab="File (YAML)"
accessLog: {}
```
```bash tab="CLI"
--accesslog
--accesslog=true
```
### `filePath`
@ -41,16 +45,23 @@ To write the logs in an asynchronous fashion, specify a `bufferingSize` option.
This option represents the number of log lines Traefik will keep in memory before writing them to the selected output.
In some cases, this option can greatly help performances.
```toml tab="File"
```toml tab="File (TOML)"
# Configuring a buffer of 100 lines
[accessLog]
filePath = "/path/to/access.log"
bufferingSize = 100
```
```yaml tab="File (YAML)"
# Configuring a buffer of 100 lines
accessLog:
filePath: "/path/to/access.log"
bufferingSize: 100
```
```bash tab="CLI"
# Configuring a buffer of 100 lines
--accesslog
--accesslog=true
--accesslog.filepath="/path/to/access.log"
--accesslog.bufferingsize=100
```
@ -66,11 +77,11 @@ The available filters are:
- `retryAttempts`, to keep the access logs when at least one retry has happened
- `minDuration`, to keep access logs when requests take longer than the specified duration
```toml tab="File"
```toml tab="File (TOML)"
# Configuring Multiple Filters
[accessLog]
filePath = "/path/to/access.log"
format = "json"
filePath = "/path/to/access.log"
format = "json"
[accessLog.filters]
statusCodes = ["200", "300-302"]
@ -78,9 +89,22 @@ format = "json"
minDuration = "10ms"
```
```yaml tab="File (YAML)"
# Configuring Multiple Filters
accessLog:
filePath: "/path/to/access.log"
format: json
filters:
statusCodes:
- "200"
- "300-302"
retryAttempts: true
minDuration: "10ms"
```
```bash tab="CLI"
# Configuring Multiple Filters
--accesslog
--accesslog=true
--accesslog.filepath="/path/to/access.log"
--accesslog.format="json"
--accesslog.filters.statuscodes="200, 300-302"
@ -100,7 +124,7 @@ Each field can be set to:
The `defaultMode` for `fields.header` is `drop`.
```toml tab="File"
```toml tab="File (TOML)"
# Limiting the Logs to Specific Fields
[accessLog]
filePath = "/path/to/access.log"
@ -121,9 +145,27 @@ The `defaultMode` for `fields.header` is `drop`.
"Content-Type" = "keep"
```
```yaml tab="File (YAML)"
# Limiting the Logs to Specific Fields
accessLog:
filePath: "/path/to/access.log"
format: json
fields:
defaultMode: keep
fields:
names:
ClientUsername: drop
headers:
defaultMode: keep
names:
- User-Agent: redact
- Authorization: drop
- Content-Type: keep
```
```bash tab="CLI"
# Limiting the Logs to Specific Fields
--accesslog
--accesslog=true
--accesslog.filepath="/path/to/access.log"
--accesslog.format="json"
--accesslog.fields.defaultmode="keep"

View file

@ -16,12 +16,18 @@ Traefik logs concern everything that happens to Traefik itself (startup, configu
By default, the logs are written to the standard output.
You can configure a file path instead using the `filePath` option.
```toml tab="File"
```toml tab="File (TOML)"
# Writing Logs to a File
[log]
filePath = "/path/to/traefik.log"
```
```yaml tab="File (YAML)"
# Writing Logs to a File
log:
filePath: "/path/to/traefik.log"
```
```bash tab="CLI"
# Writing Logs to a File
--log.filePath="/path/to/traefik.log"
@ -31,11 +37,18 @@ You can configure a file path instead using the `filePath` option.
By default, the logs use a text format (`common`), but you can also ask for the `json` format in the `format` option.
```toml tab="File"
```toml tab="File (TOML)"
# Writing Logs to a File, in JSON
[log]
filePath = "/path/to/log-file.log"
format = "json"
format = "json"
```
```yaml tab="File (YAML)"
# Writing Logs to a File, in JSON
log:
filePath: "/path/to/log-file.log"
format: json
```
```bash tab="CLI"
@ -48,11 +61,16 @@ By default, the logs use a text format (`common`), but you can also ask for the
By default, the `level` is set to `ERROR`. Alternative logging levels are `DEBUG`, `PANIC`, `FATAL`, `ERROR`, `WARN`, and `INFO`.
```toml tab="File"
```toml tab="File (TOML)"
[log]
level = "DEBUG"
```
```yaml tab="File (YAML)"
log:
level: DEBUG
```
```bash tab="CLI"
--log.level="DEBUG"
```

View file

@ -7,9 +7,13 @@ To enable the DataDog:
[metrics.dataDog]
```
```yaml tab="File (YAML)"
metrics:
dataDog: {}
```
```bash tab="CLI"
--metrics
--metrics.datadog
--metrics.datadog=true
```
#### `address`
@ -24,14 +28,13 @@ Address instructs exporter to send metrics to datadog-agent at this address.
address = "127.0.0.1:8125"
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
dataDog:
address: 127.0.0.1:8125
```
```bash tab="CLI"
--metrics
--metrics.datadog.address="127.0.0.1:8125"
```
@ -47,14 +50,13 @@ Enable metrics on entry points.
addEntryPointsLabels = true
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
dataDog:
addEntryPointsLabels: true
```
```bash tab="CLI"
--metrics
--metrics.datadog.addEntryPointsLabels=true
```
@ -70,14 +72,13 @@ Enable metrics on services.
addServicesLabels = true
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
dataDog:
addServicesLabels: true
```
```bash tab="CLI"
--metrics
--metrics.datadog.addServicesLabels=true
```
@ -93,14 +94,13 @@ The interval used by the exporter to push metrics to datadog-agent.
pushInterval = 10s
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
dataDog:
pushInterval: 10s
```
```bash tab="CLI"
--metrics
--metrics.datadog.pushInterval=10s
```

View file

@ -7,14 +7,13 @@ To enable the InfluxDB:
[metrics.influxdb]
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
influxdb: {}
```
```bash tab="CLI"
--metrics
--metrics.influxdb
--metrics.influxdb=true
```
#### `address`
@ -29,14 +28,13 @@ Address instructs exporter to send metrics to influxdb at this address.
address = "localhost:8089"
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
influxdb:
address: localhost:8089
```
```bash tab="CLI"
--metrics
--metrics.influxdb.address="localhost:8089"
```
@ -52,14 +50,13 @@ InfluxDB's address protocol (udp or http).
protocol = "upd"
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
influxdb:
protocol: udp
```
```bash tab="CLI"
--metrics
--metrics.influxdb.protocol="udp"
```
@ -75,14 +72,13 @@ InfluxDB database used when protocol is http.
database = ""
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
influxdb:
database: ""
```
```bash tab="CLI"
--metrics
--metrics.influxdb.database=""
```
@ -98,14 +94,13 @@ InfluxDB retention policy used when protocol is http.
retentionPolicy = ""
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
influxdb:
retentionPolicy: ""
```
```bash tab="CLI"
--metrics
--metrics.influxdb.retentionPolicy=""
```
@ -121,14 +116,13 @@ InfluxDB username (only with http).
username = ""
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
influxdb:
username: ""
```
```bash tab="CLI"
--metrics
--metrics.influxdb.username=""
```
@ -144,14 +138,13 @@ InfluxDB password (only with http).
password = ""
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
influxdb:
password: ""
```
```bash tab="CLI"
--metrics
--metrics.influxdb.password=""
```
@ -167,14 +160,13 @@ Enable metrics on entry points.
addEntryPointsLabels = true
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
influxdb:
addEntryPointsLabels: true
```
```bash tab="CLI"
--metrics
--metrics.influxdb.addEntryPointsLabels=true
```
@ -190,14 +182,13 @@ Enable metrics on services.
addServicesLabels = true
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
influxdb:
addServicesLabels: true
```
```bash tab="CLI"
--metrics
--metrics.influxdb.addServicesLabels=true
```
@ -213,13 +204,12 @@ The interval used by the exporter to push metrics to influxdb.
pushInterval = 10s
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
influxdb:
pushInterval: 10s
```
```bash tab="CLI"
--metrics
--metrics.influxdb.pushInterval=10s
```

View file

@ -17,10 +17,10 @@ To enable metrics:
[metrics]
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics: {}
```
```bash tab="CLI"
--metrics
--metrics=true
```

View file

@ -7,14 +7,13 @@ To enable the Prometheus:
[metrics.prometheus]
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
prometheus: {}
```
```bash tab="CLI"
--metrics
--metrics.prometheus
--metrics.prometheus=true
```
#### `buckets`
@ -29,7 +28,7 @@ Buckets for latency metrics.
buckets = [0.1,0.3,1.2,5.0]
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
prometheus:
buckets:
@ -40,7 +39,6 @@ metrics:
```
```bash tab="CLI"
--metrics
--metrics.prometheus.buckets=0.100000, 0.300000, 1.200000, 5.000000
```
@ -56,14 +54,13 @@ Enable metrics on entry points.
addEntryPointsLabels = true
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
prometheus:
addEntryPointsLabels: true
```
```bash tab="CLI"
--metrics
--metrics.prometheus.addEntryPointsLabels=true
```
@ -79,13 +76,12 @@ Enable metrics on services.
addServicesLabels = true
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
prometheus:
addServicesLabels: true
```
```bash tab="CLI"
--metrics
--metrics.prometheus.addServicesLabels=true
```

View file

@ -7,14 +7,13 @@ To enable the Statsd:
[metrics.statsd]
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
statsd: {}
```
```bash tab="CLI"
--metrics
--metrics.statsd
--metrics.statsd=true
```
#### `address`
@ -29,14 +28,13 @@ Address instructs exporter to send metrics to statsd at this address.
address = "localhost:8125"
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
statsd:
address: localhost:8125
```
```bash tab="CLI"
--metrics
--metrics.statsd.address="localhost:8125"
```
@ -52,14 +50,13 @@ Enable metrics on entry points.
addEntryPointsLabels = true
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
statsd:
addEntryPointsLabels: true
```
```bash tab="CLI"
--metrics
--metrics.statsd.addEntryPointsLabels=true
```
@ -75,14 +72,13 @@ Enable metrics on services.
addServicesLabels = true
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
statsd:
addServicesLabels: true
```
```bash tab="CLI"
--metrics
--metrics.statsd.addServicesLabels=true
```
@ -98,13 +94,12 @@ The interval used by the exporter to push metrics to statsD.
pushInterval = 10s
```
```yaml tab="File (TOML)"
```yaml tab="File (YAML)"
metrics:
statsd:
pushInterval: 10s
```
```bash tab="CLI"
--metrics
--metrics.statsd.pushInterval=10s
```

View file

@ -13,8 +13,7 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.datadog
--tracing.datadog=true
```
#### `localAgentHostPort`
@ -36,7 +35,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.datadog.localAgentHostPort="127.0.0.1:8126"
```
@ -59,7 +57,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.datadog.debug=true
```
@ -82,7 +79,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.datadog.globalTag="sample"
```
@ -106,6 +102,5 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.datadog.prioritySampling=true
```

View file

@ -13,8 +13,7 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.haystack
--tracing.haystack=true
```
#### `localAgentHost`
@ -36,7 +35,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.haystack.localAgentHost="127.0.0.1"
```
@ -59,7 +57,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.haystack.localAgentPort=42699
```
@ -82,7 +79,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.haystack.globalTag="sample:test"
```
@ -105,7 +101,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.haystack.traceIDHeaderName="sample"
```
@ -128,7 +123,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.haystack.parentIDHeaderName="sample"
```
@ -151,7 +145,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.haystack.spanIDHeaderName=sample:test
```
@ -175,6 +168,5 @@ tracing:
```bash tab="CLI"
--tracing
--tracing.haystack.baggagePrefixHeaderName="sample"
```

View file

@ -13,8 +13,7 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.instana
--tracing.instana=true
```
#### `localAgentHost`
@ -36,7 +35,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.instana.localAgentHost="127.0.0.1"
```
@ -59,7 +57,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.instana.localAgentPort=42699
```
@ -89,6 +86,5 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.instana.logLevel="info"
```

View file

@ -13,8 +13,7 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.jaeger
--tracing.jaeger=true
```
!!! warning
@ -40,7 +39,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.jaeger.samplingServerURL="http://localhost:5778/sampling"
```
@ -63,7 +61,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.jaeger.samplingType="const"
```
@ -92,7 +89,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.jaeger.samplingParam="1.0"
```
@ -115,7 +111,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.jaeger.localAgentHostPort="127.0.0.1:6831"
```
@ -138,7 +133,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.jaeger.gen128Bit
```
@ -165,7 +159,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.jaeger.propagation="jaeger"
```
@ -189,7 +182,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.jaeger.traceContextHeaderName="uber-trace-id"
```
@ -214,7 +206,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.jaeger.collector.endpoint="http://127.0.0.1:14268/api/traces?format=jaeger.thrift"
```
@ -238,7 +229,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.jaeger.collector.user="my-user"
```
@ -262,6 +252,5 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.jaeger.collector.password="my-password"
```

View file

@ -30,7 +30,7 @@ tracing: {}
```
```bash tab="CLI"
--tracing
--tracing=true
```
### Common Options
@ -52,7 +52,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.serviceName="traefik"
```
@ -76,6 +75,5 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.spanNameLimit=150
```

View file

@ -13,8 +13,7 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.zipkin
--tracing.zipkin=true
```
#### `httpEndpoint`
@ -36,7 +35,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.zipkin.httpEndpoint="http://localhost:9411/api/v1/spans"
```
@ -59,7 +57,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.zipkin.debug=true
```
@ -82,7 +79,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.zipkin.sameSpan=true
```
@ -105,7 +101,6 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.zipkin.id128Bit=false
```
@ -128,6 +123,5 @@ tracing:
```
```bash tab="CLI"
--tracing
--tracing.zipkin.sampleRate="0.2"
```

View file

@ -29,12 +29,16 @@ would be to apply the following protection mechanisms:
To enable the API handler:
```toml tab="File"
```toml tab="File (TOML)"
[api]
```
```yaml tab="File (YAML)"
api: {}
```
```bash tab="CLI"
--api
--api=true
```
### `dashboard`
@ -43,13 +47,18 @@ _Optional, Default=true_
Enable the dashboard. More about the dashboard features [here](./dashboard.md).
```toml tab="File"
```toml tab="File (TOML)"
[api]
dashboard = true
```
```yaml tab="File (YAML)"
api:
dashboard: true
```
```bash tab="CLI"
--api.dashboard
--api.dashboard=true
```
### `debug`
@ -58,11 +67,16 @@ _Optional, Default=false_
Enable additional endpoints for debugging and profiling, served under `/debug/`.
```toml tab="File"
```toml tab="File (TOML)"
[api]
debug = true
```
```yaml tab="File (YAML)"
api:
debug: true
```
```bash tab="CLI"
--api.debug=true
```

View file

@ -29,37 +29,38 @@ By default, the dashboard is available on `/` on port `:8080`.
To enable the dashboard, you need to enable Traefik's API.
??? example "Using the Command Line"
```toml tab="File (TOML)"
[api]
# Dashboard
#
# Optional
# Default: true
#
dashboard = true
```
| Option | Values | Default Value |
| --------------- | --------------- | --------------------: |
| --api | \[true\|false\] | false |
| --api.dashboard | \[true\|false\] | true when api is true |
```yaml tab="File (YAML)"
api:
# Dashboard
#
# Optional
# Default: true
#
dashboard: true
```
{!more-on-command-line.md!}
```bash tab="CLI"
# Dashboard
#
# Optional
# Default: true
#
--api.dashboard=true
```
??? example "Using the Configuration File"
{!more-on-command-line.md!}
```toml
[api]
# Dashboard
#
# Optional
# Default: true
#
dashboard = true
```
{!more-on-configuration-file.md!}
??? example "Using a Key/Value Store"
| Key | Values | Default Value |
| ------------- | --------------- | --------------------: |
| api | \[true\|false\] | false |
| api.dashboard | \[true\|false\] | true when api is true |
{!more-on-key-value-store.md!}
{!more-on-configuration-file.md!}
!!! tip "Did You Know?"
The API provides more features than the Dashboard.

View file

@ -7,9 +7,17 @@ Checking the Health of Your Traefik Instances
??? example "Enabling /ping"
```toml
[ping]
```
```toml tab="File (TOML)"
[ping]
```
```yaml tab="File (YAML)"
ping: {}
```
```bash tab="CLI"
--ping=true
```
| Path | Method | Description |
|---------|---------------|-----------------------------------------------------------------------------------------------------|

View file

@ -26,7 +26,7 @@ Attach labels to your containers and let Traefik do the rest!
```
```bash tab="CLI"
--providers.docker
--providers.docker=true
```
Attaching labels to containers (in your docker compose file)
@ -65,7 +65,7 @@ Attach labels to your containers and let Traefik do the rest!
```bash tab="CLI"
--providers.docker.endpoint="tcp://127.0.0.1:2375"
--providers.docker.swarmMode
--providers.docker.swarmMode=true
```
Attach labels to services (not to containers) while in Swarm mode (in your docker compose file)
@ -331,7 +331,7 @@ providers:
```
```bash tab="CLI"
--providers.docker.swarmMode
--providers.docker.swarmMode=true
# ...
```

View file

@ -20,7 +20,7 @@ providers:
```
```bash tab="CLI"
--providers.kubernetesingress
--providers.kubernetesingress=true
```
The provider then watches for incoming ingresses events, such as the example below, and derives the corresponding dynamic configuration from it, which in turn will create the resulting routers, services, handlers, etc.

View file

@ -21,7 +21,7 @@ See also [Marathon user guide](../user-guides/marathon.md).
```
```bash tab="CLI"
--providers.marathon
--providers.marathon=true
```
Attaching labels to marathon applications

View file

@ -28,7 +28,7 @@ Attach labels to your services and let Traefik do the rest!
```
```bash tab="CLI"
--providers.rancher
--providers.rancher=true
```
Attaching labels to services
@ -55,6 +55,8 @@ Attach labels to your services and let Traefik do the rest!
--8<-- "content/providers/rancher.txt"
```
List of all available labels for the [dynamic](../reference/dynamic-configuration/rancher.md) configuration references.
### `exposedByDefault`
_Optional, Default=true_

View file

@ -11,7 +11,7 @@
enableServiceHealthFilter = true
# Defines the polling interval (in seconds).
refreshSeconds = true
refreshSeconds = 15
# Poll the Rancher metadata service for changes every `rancher.refreshSeconds`, which is less accurate
intervalPoll = false

View file

@ -1,5 +1,5 @@
# Enable Rancher Provider.
--providers.rancher
--providers.rancher=true
# Expose Rancher services by default in Traefik.
--providers.rancher.exposedByDefault=true
@ -11,7 +11,7 @@
--providers.rancher.enableServiceHealthFilter=true
# Defines the polling interval (in seconds).
--providers.rancher.refreshSeconds=true
--providers.rancher.refreshSeconds=15
# Poll the Rancher metadata service for changes every `rancher.refreshSeconds`, which is less accurate
--providers.rancher.intervalPoll=false

View file

@ -12,7 +12,7 @@ providers:
enableServiceHealthFilter: true
# Defines the polling interval (in seconds).
refreshSeconds: true
refreshSeconds: 15
# Poll the Rancher metadata service for changes every `rancher.refreshSeconds`, which is less accurate
intervalPoll: false

View file

@ -0,0 +1,177 @@
- "traefik.http.middlewares.middleware00.addprefix.prefix=foobar"
- "traefik.http.middlewares.middleware01.basicauth.headerfield=foobar"
- "traefik.http.middlewares.middleware01.basicauth.realm=foobar"
- "traefik.http.middlewares.middleware01.basicauth.removeheader=true"
- "traefik.http.middlewares.middleware01.basicauth.users=foobar, foobar"
- "traefik.http.middlewares.middleware01.basicauth.usersfile=foobar"
- "traefik.http.middlewares.middleware02.buffering.maxrequestbodybytes=42"
- "traefik.http.middlewares.middleware02.buffering.maxresponsebodybytes=42"
- "traefik.http.middlewares.middleware02.buffering.memrequestbodybytes=42"
- "traefik.http.middlewares.middleware02.buffering.memresponsebodybytes=42"
- "traefik.http.middlewares.middleware02.buffering.retryexpression=foobar"
- "traefik.http.middlewares.middleware03.chain.middlewares=foobar, foobar"
- "traefik.http.middlewares.middleware04.circuitbreaker.expression=foobar"
- "traefik.http.middlewares.middleware05.compress=true"
- "traefik.http.middlewares.middleware06.digestauth.headerfield=foobar"
- "traefik.http.middlewares.middleware06.digestauth.realm=foobar"
- "traefik.http.middlewares.middleware06.digestauth.removeheader=true"
- "traefik.http.middlewares.middleware06.digestauth.users=foobar, foobar"
- "traefik.http.middlewares.middleware06.digestauth.usersfile=foobar"
- "traefik.http.middlewares.middleware07.errors.query=foobar"
- "traefik.http.middlewares.middleware07.errors.service=foobar"
- "traefik.http.middlewares.middleware07.errors.status=foobar, foobar"
- "traefik.http.middlewares.middleware08.forwardauth.address=foobar"
- "traefik.http.middlewares.middleware08.forwardauth.authresponseheaders=foobar, foobar"
- "traefik.http.middlewares.middleware08.forwardauth.tls.ca=foobar"
- "traefik.http.middlewares.middleware08.forwardauth.tls.caoptional=true"
- "traefik.http.middlewares.middleware08.forwardauth.tls.cert=foobar"
- "traefik.http.middlewares.middleware08.forwardauth.tls.insecureskipverify=true"
- "traefik.http.middlewares.middleware08.forwardauth.tls.key=foobar"
- "traefik.http.middlewares.middleware08.forwardauth.trustforwardheader=true"
- "traefik.http.middlewares.middleware09.headers.accesscontrolallowcredentials=true"
- "traefik.http.middlewares.middleware09.headers.accesscontrolallowheaders=foobar, foobar"
- "traefik.http.middlewares.middleware09.headers.accesscontrolallowmethods=foobar, foobar"
- "traefik.http.middlewares.middleware09.headers.accesscontrolalloworigin=foobar"
- "traefik.http.middlewares.middleware09.headers.accesscontrolexposeheaders=foobar, foobar"
- "traefik.http.middlewares.middleware09.headers.accesscontrolmaxage=42"
- "traefik.http.middlewares.middleware09.headers.addvaryheader=true"
- "traefik.http.middlewares.middleware09.headers.allowedhosts=foobar, foobar"
- "traefik.http.middlewares.middleware09.headers.browserxssfilter=true"
- "traefik.http.middlewares.middleware09.headers.contentsecuritypolicy=foobar"
- "traefik.http.middlewares.middleware09.headers.contenttypenosniff=true"
- "traefik.http.middlewares.middleware09.headers.custombrowserxssvalue=foobar"
- "traefik.http.middlewares.middleware09.headers.customframeoptionsvalue=foobar"
- "traefik.http.middlewares.middleware09.headers.customrequestheaders.name0=foobar"
- "traefik.http.middlewares.middleware09.headers.customrequestheaders.name1=foobar"
- "traefik.http.middlewares.middleware09.headers.customresponseheaders.name0=foobar"
- "traefik.http.middlewares.middleware09.headers.customresponseheaders.name1=foobar"
- "traefik.http.middlewares.middleware09.headers.forcestsheader=true"
- "traefik.http.middlewares.middleware09.headers.framedeny=true"
- "traefik.http.middlewares.middleware09.headers.hostsproxyheaders=foobar, foobar"
- "traefik.http.middlewares.middleware09.headers.isdevelopment=true"
- "traefik.http.middlewares.middleware09.headers.publickey=foobar"
- "traefik.http.middlewares.middleware09.headers.referrerpolicy=foobar"
- "traefik.http.middlewares.middleware09.headers.sslforcehost=true"
- "traefik.http.middlewares.middleware09.headers.sslhost=foobar"
- "traefik.http.middlewares.middleware09.headers.sslproxyheaders.name0=foobar"
- "traefik.http.middlewares.middleware09.headers.sslproxyheaders.name1=foobar"
- "traefik.http.middlewares.middleware09.headers.sslredirect=true"
- "traefik.http.middlewares.middleware09.headers.ssltemporaryredirect=true"
- "traefik.http.middlewares.middleware09.headers.stsincludesubdomains=true"
- "traefik.http.middlewares.middleware09.headers.stspreload=true"
- "traefik.http.middlewares.middleware09.headers.stsseconds=42"
- "traefik.http.middlewares.middleware10.ipwhitelist.ipstrategy.depth=42"
- "traefik.http.middlewares.middleware10.ipwhitelist.ipstrategy.excludedips=foobar, foobar"
- "traefik.http.middlewares.middleware10.ipwhitelist.sourcerange=foobar, foobar"
- "traefik.http.middlewares.middleware11.maxconn.amount=42"
- "traefik.http.middlewares.middleware11.maxconn.extractorfunc=foobar"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.commonname=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.country=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.domaincomponent=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.locality=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.organization=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.province=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.serialnumber=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.notafter=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.notbefore=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.sans=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.commonname=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.country=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.domaincomponent=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.locality=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.organization=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.province=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.serialnumber=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.pem=true"
- "traefik.http.middlewares.middleware13.redirectregex.permanent=true"
- "traefik.http.middlewares.middleware13.redirectregex.regex=foobar"
- "traefik.http.middlewares.middleware13.redirectregex.replacement=foobar"
- "traefik.http.middlewares.middleware14.redirectscheme.permanent=true"
- "traefik.http.middlewares.middleware14.redirectscheme.port=foobar"
- "traefik.http.middlewares.middleware14.redirectscheme.scheme=foobar"
- "traefik.http.middlewares.middleware15.replacepath.path=foobar"
- "traefik.http.middlewares.middleware16.replacepathregex.regex=foobar"
- "traefik.http.middlewares.middleware16.replacepathregex.replacement=foobar"
- "traefik.http.middlewares.middleware17.retry.attempts=42"
- "traefik.http.middlewares.middleware18.stripprefix.prefixes=foobar, foobar"
- "traefik.http.middlewares.middleware19.stripprefixregex.regex=foobar, foobar"
- "traefik.http.routers.router0.entrypoints=foobar, foobar"
- "traefik.http.routers.router0.middlewares=foobar, foobar"
- "traefik.http.routers.router0.priority=42"
- "traefik.http.routers.router0.rule=foobar"
- "traefik.http.routers.router0.service=foobar"
- "traefik.http.routers.router0.tls=true"
- "traefik.http.routers.router0.tls.certresolver=foobar"
- "traefik.http.routers.router0.tls.domains[0].main=foobar"
- "traefik.http.routers.router0.tls.domains[0].sans=foobar, foobar"
- "traefik.http.routers.router0.tls.domains[1].main=foobar"
- "traefik.http.routers.router0.tls.domains[1].sans=foobar, foobar"
- "traefik.http.routers.router0.tls.options=foobar"
- "traefik.http.routers.router1.entrypoints=foobar, foobar"
- "traefik.http.routers.router1.middlewares=foobar, foobar"
- "traefik.http.routers.router1.priority=42"
- "traefik.http.routers.router1.rule=foobar"
- "traefik.http.routers.router1.service=foobar"
- "traefik.http.routers.router1.tls=true"
- "traefik.http.routers.router1.tls.certresolver=foobar"
- "traefik.http.routers.router1.tls.domains[0].main=foobar"
- "traefik.http.routers.router1.tls.domains[0].sans=foobar, foobar"
- "traefik.http.routers.router1.tls.domains[1].main=foobar"
- "traefik.http.routers.router1.tls.domains[1].sans=foobar, foobar"
- "traefik.http.routers.router1.tls.options=foobar"
- "traefik.http.services.service0.loadbalancer.healthcheck.headers.name0=foobar"
- "traefik.http.services.service0.loadbalancer.healthcheck.headers.name1=foobar"
- "traefik.http.services.service0.loadbalancer.healthcheck.hostname=foobar"
- "traefik.http.services.service0.loadbalancer.healthcheck.interval=foobar"
- "traefik.http.services.service0.loadbalancer.healthcheck.path=foobar"
- "traefik.http.services.service0.loadbalancer.healthcheck.port=42"
- "traefik.http.services.service0.loadbalancer.healthcheck.scheme=foobar"
- "traefik.http.services.service0.loadbalancer.healthcheck.timeout=foobar"
- "traefik.http.services.service0.loadbalancer.passhostheader=true"
- "traefik.http.services.service0.loadbalancer.responseforwarding.flushinterval=foobar"
- "traefik.http.services.service0.loadbalancer.stickiness=true"
- "traefik.http.services.service0.loadbalancer.stickiness.cookiename=foobar"
- "traefik.http.services.service0.loadbalancer.stickiness.httponlycookie=true"
- "traefik.http.services.service0.loadbalancer.stickiness.securecookie=true"
- "traefik.http.services.service0.loadbalancer.server.port=foobar"
- "traefik.http.services.service0.loadbalancer.server.scheme=foobar"
- "traefik.http.services.service1.loadbalancer.healthcheck.headers.name0=foobar"
- "traefik.http.services.service1.loadbalancer.healthcheck.headers.name1=foobar"
- "traefik.http.services.service1.loadbalancer.healthcheck.hostname=foobar"
- "traefik.http.services.service1.loadbalancer.healthcheck.interval=foobar"
- "traefik.http.services.service1.loadbalancer.healthcheck.path=foobar"
- "traefik.http.services.service1.loadbalancer.healthcheck.port=42"
- "traefik.http.services.service1.loadbalancer.healthcheck.scheme=foobar"
- "traefik.http.services.service1.loadbalancer.healthcheck.timeout=foobar"
- "traefik.http.services.service1.loadbalancer.passhostheader=true"
- "traefik.http.services.service1.loadbalancer.responseforwarding.flushinterval=foobar"
- "traefik.http.services.service1.loadbalancer.stickiness=true"
- "traefik.http.services.service1.loadbalancer.stickiness.cookiename=foobar"
- "traefik.http.services.service1.loadbalancer.stickiness.httponlycookie=true"
- "traefik.http.services.service1.loadbalancer.stickiness.securecookie=true"
- "traefik.http.services.service1.loadbalancer.server.port=foobar"
- "traefik.http.services.service1.loadbalancer.server.scheme=foobar"
- "traefik.tcp.routers.tcprouter0.entrypoints=foobar, foobar"
- "traefik.tcp.routers.tcprouter0.rule=foobar"
- "traefik.tcp.routers.tcprouter0.service=foobar"
- "traefik.tcp.routers.tcprouter0.tls=true"
- "traefik.tcp.routers.tcprouter0.tls.certresolver=foobar"
- "traefik.tcp.routers.tcprouter0.tls.domains[0].main=foobar"
- "traefik.tcp.routers.tcprouter0.tls.domains[0].sans=foobar, foobar"
- "traefik.tcp.routers.tcprouter0.tls.domains[1].main=foobar"
- "traefik.tcp.routers.tcprouter0.tls.domains[1].sans=foobar, foobar"
- "traefik.tcp.routers.tcprouter0.tls.options=foobar"
- "traefik.tcp.routers.tcprouter0.tls.passthrough=true"
- "traefik.tcp.routers.tcprouter1.entrypoints=foobar, foobar"
- "traefik.tcp.routers.tcprouter1.rule=foobar"
- "traefik.tcp.routers.tcprouter1.service=foobar"
- "traefik.tcp.routers.tcprouter1.tls=true"
- "traefik.tcp.routers.tcprouter1.tls.certresolver=foobar"
- "traefik.tcp.routers.tcprouter1.tls.domains[0].main=foobar"
- "traefik.tcp.routers.tcprouter1.tls.domains[0].sans=foobar, foobar"
- "traefik.tcp.routers.tcprouter1.tls.domains[1].main=foobar"
- "traefik.tcp.routers.tcprouter1.tls.domains[1].sans=foobar, foobar"
- "traefik.tcp.routers.tcprouter1.tls.options=foobar"
- "traefik.tcp.routers.tcprouter1.tls.passthrough=true"
- "traefik.tcp.services.tcpservice0.loadbalancer.server.port=foobar"
- "traefik.tcp.services.tcpservice1.loadbalancer.server.port=foobar"

View file

@ -7,6 +7,6 @@ The labels are case insensitive.
```yaml
labels:
--8<-- "content/reference/dynamic-configuration/docker.yml"
--8<-- "content/reference/dynamic-configuration/labels.yml"
--8<-- "content/reference/dynamic-configuration/docker.yml"
--8<-- "content/reference/dynamic-configuration/docker-labels.yml"
```

View file

@ -1,3 +1,3 @@
- "traefik.enable=true"
- "traefik.docker.network=foobar"
- "traefik.docker.lbswarm=true"
- "traefik.enable=true"
- "traefik.docker.network=foobar"
- "traefik.docker.lbswarm=true"

View file

@ -8,6 +8,15 @@
priority = 42
[http.routers.Router0.tls]
options = "foobar"
certResolver = "foobar"
[[http.routers.Router0.tls.domains]]
main = "foobar"
sans = ["foobar", "foobar"]
[[http.routers.Router0.tls.domains]]
main = "foobar"
sans = ["foobar", "foobar"]
[http.routers.Router1]
entryPoints = ["foobar", "foobar"]
middlewares = ["foobar", "foobar"]
@ -16,6 +25,15 @@
priority = 42
[http.routers.Router1.tls]
options = "foobar"
certResolver = "foobar"
[[http.routers.Router1.tls.domains]]
main = "foobar"
sans = ["foobar", "foobar"]
[[http.routers.Router1.tls.domains]]
main = "foobar"
sans = ["foobar", "foobar"]
[http.services]
[http.services.Service0]
[http.services.Service0.loadBalancer]
@ -186,31 +204,31 @@
commonName = true
serialNumber = true
domainComponent = true
[http.middlewares.Middleware14]
[http.middlewares.Middleware14.redirectRegex]
[http.middlewares.Middleware13]
[http.middlewares.Middleware13.redirectRegex]
regex = "foobar"
replacement = "foobar"
permanent = true
[http.middlewares.Middleware15]
[http.middlewares.Middleware15.redirectScheme]
[http.middlewares.Middleware14]
[http.middlewares.Middleware14.redirectScheme]
scheme = "foobar"
port = "foobar"
permanent = true
[http.middlewares.Middleware16]
[http.middlewares.Middleware16.replacePath]
[http.middlewares.Middleware15]
[http.middlewares.Middleware15.replacePath]
path = "foobar"
[http.middlewares.Middleware17]
[http.middlewares.Middleware17.replacePathRegex]
[http.middlewares.Middleware16]
[http.middlewares.Middleware16.replacePathRegex]
regex = "foobar"
replacement = "foobar"
[http.middlewares.Middleware18]
[http.middlewares.Middleware18.retry]
[http.middlewares.Middleware17]
[http.middlewares.Middleware17.retry]
attempts = 42
[http.middlewares.Middleware19]
[http.middlewares.Middleware19.stripPrefix]
[http.middlewares.Middleware18]
[http.middlewares.Middleware18.stripPrefix]
prefixes = ["foobar", "foobar"]
[http.middlewares.Middleware20]
[http.middlewares.Middleware20.stripPrefixRegex]
[http.middlewares.Middleware19]
[http.middlewares.Middleware19.stripPrefixRegex]
regex = ["foobar", "foobar"]
[tcp]
@ -222,6 +240,15 @@
[tcp.routers.TCPRouter0.tls]
passthrough = true
options = "foobar"
certResolver = "foobar"
[[tcp.routers.TCPRouter0.tls.domains]]
main = "foobar"
sans = ["foobar", "foobar"]
[[tcp.routers.TCPRouter0.tls.domains]]
main = "foobar"
sans = ["foobar", "foobar"]
[tcp.routers.TCPRouter1]
entryPoints = ["foobar", "foobar"]
service = "foobar"
@ -229,6 +256,15 @@
[tcp.routers.TCPRouter1.tls]
passthrough = true
options = "foobar"
certResolver = "foobar"
[[tcp.routers.TCPRouter1.tls.domains]]
main = "foobar"
sans = ["foobar", "foobar"]
[[tcp.routers.TCPRouter1.tls.domains]]
main = "foobar"
sans = ["foobar", "foobar"]
[tcp.services]
[tcp.services.TCPService0]
[tcp.services.TCPService0.loadBalancer]
@ -265,14 +301,14 @@
sniStrict = true
[tls.options.Options0.clientAuth]
caFiles = ["foobar", "foobar"]
clientAuthType = "VerifyClientCertIfGiven"
clientAuthType = "foobar"
[tls.options.Options1]
minVersion = "foobar"
cipherSuites = ["foobar", "foobar"]
sniStrict = true
[tls.options.Options1.clientAuth]
caFiles = ["foobar", "foobar"]
clientAuthType = "VerifyClientCertIfGiven"
clientAuthType = "foobar"
[tls.stores]
[tls.stores.Store0]
[tls.stores.Store0.defaultCertificate]

View file

@ -12,6 +12,16 @@ http:
priority: 42
tls:
options: foobar
certResolver: foobar
domains:
- main: foobar
sans:
- foobar
- foobar
- main: foobar
sans:
- foobar
- foobar
Router1:
entryPoints:
- foobar
@ -24,6 +34,16 @@ http:
priority: 42
tls:
options: foobar
certResolver: foobar
domains:
- main: foobar
sans:
- foobar
- foobar
- main: foobar
sans:
- foobar
- foobar
services:
Service0:
loadBalancer:
@ -212,32 +232,32 @@ http:
commonName: true
serialNumber: true
domainComponent: true
Middleware14:
Middleware13:
redirectRegex:
regex: foobar
replacement: foobar
permanent: true
Middleware15:
Middleware14:
redirectScheme:
scheme: foobar
port: foobar
permanent: true
Middleware16:
Middleware15:
replacePath:
path: foobar
Middleware17:
Middleware16:
replacePathRegex:
regex: foobar
replacement: foobar
Middleware18:
Middleware17:
retry:
attempts: 42
Middleware19:
Middleware18:
stripPrefix:
prefixes:
- foobar
- foobar
Middleware20:
Middleware19:
stripPrefixRegex:
regex:
- foobar
@ -253,6 +273,16 @@ tcp:
tls:
passthrough: true
options: foobar
certResolver: foobar
domains:
- main: foobar
sans:
- foobar
- foobar
- main: foobar
sans:
- foobar
- foobar
TCPRouter1:
entryPoints:
- foobar
@ -262,6 +292,16 @@ tcp:
tls:
passthrough: true
options: foobar
certResolver: foobar
domains:
- main: foobar
sans:
- foobar
- foobar
- main: foobar
sans:
- foobar
- foobar
services:
TCPService0:
loadBalancer:
@ -295,7 +335,7 @@ tls:
caFiles:
- foobar
- foobar
clientAuthType: VerifyClientCertIfGiven
clientAuthType: foobar
sniStrict: true
Options1:
minVersion: foobar
@ -306,7 +346,7 @@ tls:
caFiles:
- foobar
- foobar
clientAuthType: VerifyClientCertIfGiven
clientAuthType: foobar
sniStrict: true
stores:
Store0:

View file

@ -1,157 +0,0 @@
- "traefik.http.middlewares.middleware00.addprefix.prefix=foobar"
- "traefik.http.middlewares.middleware01.basicauth.headerfield=foobar"
- "traefik.http.middlewares.middleware01.basicauth.realm=foobar"
- "traefik.http.middlewares.middleware01.basicauth.removeheader=true"
- "traefik.http.middlewares.middleware01.basicauth.users=foobar, foobar"
- "traefik.http.middlewares.middleware01.basicauth.usersfile=foobar"
- "traefik.http.middlewares.middleware02.buffering.maxrequestbodybytes=42"
- "traefik.http.middlewares.middleware02.buffering.maxresponsebodybytes=42"
- "traefik.http.middlewares.middleware02.buffering.memrequestbodybytes=42"
- "traefik.http.middlewares.middleware02.buffering.memresponsebodybytes=42"
- "traefik.http.middlewares.middleware02.buffering.retryexpression=foobar"
- "traefik.http.middlewares.middleware03.chain.middlewares=foobar, foobar"
- "traefik.http.middlewares.middleware04.circuitbreaker.expression=foobar"
- "traefik.http.middlewares.middleware05.compress=true"
- "traefik.http.middlewares.middleware06.digestauth.headerfield=foobar"
- "traefik.http.middlewares.middleware06.digestauth.realm=foobar"
- "traefik.http.middlewares.middleware06.digestauth.removeheader=true"
- "traefik.http.middlewares.middleware06.digestauth.users=foobar, foobar"
- "traefik.http.middlewares.middleware06.digestauth.usersfile=foobar"
- "traefik.http.middlewares.middleware07.errors.query=foobar"
- "traefik.http.middlewares.middleware07.errors.service=foobar"
- "traefik.http.middlewares.middleware07.errors.status=foobar, foobar"
- "traefik.http.middlewares.middleware08.forwardauth.address=foobar"
- "traefik.http.middlewares.middleware08.forwardauth.authresponseheaders=foobar, foobar"
- "traefik.http.middlewares.middleware08.forwardauth.tls.ca=foobar"
- "traefik.http.middlewares.middleware08.forwardauth.tls.caoptional=true"
- "traefik.http.middlewares.middleware08.forwardauth.tls.cert=foobar"
- "traefik.http.middlewares.middleware08.forwardauth.tls.insecureskipverify=true"
- "traefik.http.middlewares.middleware08.forwardauth.tls.key=foobar"
- "traefik.http.middlewares.middleware08.forwardauth.trustforwardheader=true"
- "traefik.http.middlewares.middleware09.headers.accesscontrolallowcredentials=true"
- "traefik.http.middlewares.middleware09.headers.accesscontrolallowheaders=foobar, foobar"
- "traefik.http.middlewares.middleware09.headers.accesscontrolallowmethods=foobar, foobar"
- "traefik.http.middlewares.middleware09.headers.accesscontrolalloworigin=foobar"
- "traefik.http.middlewares.middleware09.headers.accesscontrolexposeheaders=foobar, foobar"
- "traefik.http.middlewares.middleware09.headers.accesscontrolmaxage=42"
- "traefik.http.middlewares.middleware09.headers.addvaryheader=true"
- "traefik.http.middlewares.middleware09.headers.allowedhosts=foobar, foobar"
- "traefik.http.middlewares.middleware09.headers.browserxssfilter=true"
- "traefik.http.middlewares.middleware09.headers.contentsecuritypolicy=foobar"
- "traefik.http.middlewares.middleware09.headers.contenttypenosniff=true"
- "traefik.http.middlewares.middleware09.headers.custombrowserxssvalue=foobar"
- "traefik.http.middlewares.middleware09.headers.customframeoptionsvalue=foobar"
- "traefik.http.middlewares.middleware09.headers.customrequestheaders.name0=foobar"
- "traefik.http.middlewares.middleware09.headers.customrequestheaders.name1=foobar"
- "traefik.http.middlewares.middleware09.headers.customresponseheaders.name0=foobar"
- "traefik.http.middlewares.middleware09.headers.customresponseheaders.name1=foobar"
- "traefik.http.middlewares.middleware09.headers.forcestsheader=true"
- "traefik.http.middlewares.middleware09.headers.framedeny=true"
- "traefik.http.middlewares.middleware09.headers.hostsproxyheaders=foobar, foobar"
- "traefik.http.middlewares.middleware09.headers.isdevelopment=true"
- "traefik.http.middlewares.middleware09.headers.publickey=foobar"
- "traefik.http.middlewares.middleware09.headers.referrerpolicy=foobar"
- "traefik.http.middlewares.middleware09.headers.sslforcehost=true"
- "traefik.http.middlewares.middleware09.headers.sslhost=foobar"
- "traefik.http.middlewares.middleware09.headers.sslproxyheaders.name0=foobar"
- "traefik.http.middlewares.middleware09.headers.sslproxyheaders.name1=foobar"
- "traefik.http.middlewares.middleware09.headers.sslredirect=true"
- "traefik.http.middlewares.middleware09.headers.ssltemporaryredirect=true"
- "traefik.http.middlewares.middleware09.headers.stsincludesubdomains=true"
- "traefik.http.middlewares.middleware09.headers.stspreload=true"
- "traefik.http.middlewares.middleware09.headers.stsseconds=42"
- "traefik.http.middlewares.middleware10.ipwhitelist.ipstrategy.depth=42"
- "traefik.http.middlewares.middleware10.ipwhitelist.ipstrategy.excludedips=foobar, foobar"
- "traefik.http.middlewares.middleware10.ipwhitelist.sourcerange=foobar, foobar"
- "traefik.http.middlewares.middleware11.maxconn.amount=42"
- "traefik.http.middlewares.middleware11.maxconn.extractorfunc=foobar"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.commonname=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.country=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.domaincomponent=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.locality=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.organization=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.province=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.serialnumber=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.notafter=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.notbefore=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.sans=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.commonname=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.country=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.domaincomponent=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.locality=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.organization=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.province=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.serialnumber=true"
- "traefik.http.middlewares.middleware12.passtlsclientcert.pem=true"
- "traefik.http.middlewares.middleware14.redirectregex.permanent=true"
- "traefik.http.middlewares.middleware14.redirectregex.regex=foobar"
- "traefik.http.middlewares.middleware14.redirectregex.replacement=foobar"
- "traefik.http.middlewares.middleware15.redirectscheme.permanent=true"
- "traefik.http.middlewares.middleware15.redirectscheme.port=foobar"
- "traefik.http.middlewares.middleware15.redirectscheme.scheme=foobar"
- "traefik.http.middlewares.middleware16.replacepath.path=foobar"
- "traefik.http.middlewares.middleware17.replacepathregex.regex=foobar"
- "traefik.http.middlewares.middleware17.replacepathregex.replacement=foobar"
- "traefik.http.middlewares.middleware18.retry.attempts=42"
- "traefik.http.middlewares.middleware19.stripprefix.prefixes=foobar, foobar"
- "traefik.http.middlewares.middleware20.stripprefixregex.regex=foobar, foobar"
- "traefik.http.routers.router0.entrypoints=foobar, foobar"
- "traefik.http.routers.router0.middlewares=foobar, foobar"
- "traefik.http.routers.router0.priority=42"
- "traefik.http.routers.router0.rule=foobar"
- "traefik.http.routers.router0.service=foobar"
- "traefik.http.routers.router0.tls=true"
- "traefik.http.routers.router0.tls.options=foobar"
- "traefik.http.routers.router1.entrypoints=foobar, foobar"
- "traefik.http.routers.router1.middlewares=foobar, foobar"
- "traefik.http.routers.router1.priority=42"
- "traefik.http.routers.router1.rule=foobar"
- "traefik.http.routers.router1.service=foobar"
- "traefik.http.routers.router1.tls=true"
- "traefik.http.routers.router1.tls.options=foobar"
- "traefik.http.services.service0.loadbalancer.healthcheck.headers.name0=foobar"
- "traefik.http.services.service0.loadbalancer.healthcheck.headers.name1=foobar"
- "traefik.http.services.service0.loadbalancer.healthcheck.hostname=foobar"
- "traefik.http.services.service0.loadbalancer.healthcheck.interval=foobar"
- "traefik.http.services.service0.loadbalancer.healthcheck.path=foobar"
- "traefik.http.services.service0.loadbalancer.healthcheck.port=42"
- "traefik.http.services.service0.loadbalancer.healthcheck.scheme=foobar"
- "traefik.http.services.service0.loadbalancer.healthcheck.timeout=foobar"
- "traefik.http.services.service0.loadbalancer.passhostheader=true"
- "traefik.http.services.service0.loadbalancer.responseforwarding.flushinterval=foobar"
- "traefik.http.services.service0.loadbalancer.stickiness=true"
- "traefik.http.services.service0.loadbalancer.stickiness.cookiename=foobar"
- "traefik.http.services.service0.loadbalancer.stickiness.httponlycookie=true"
- "traefik.http.services.service0.loadbalancer.stickiness.securecookie=true"
- "traefik.http.services.service0.loadbalancer.server.port=foobar"
- "traefik.http.services.service0.loadbalancer.server.scheme=foobar"
- "traefik.http.services.service1.loadbalancer.healthcheck.headers.name0=foobar"
- "traefik.http.services.service1.loadbalancer.healthcheck.headers.name1=foobar"
- "traefik.http.services.service1.loadbalancer.healthcheck.hostname=foobar"
- "traefik.http.services.service1.loadbalancer.healthcheck.interval=foobar"
- "traefik.http.services.service1.loadbalancer.healthcheck.path=foobar"
- "traefik.http.services.service1.loadbalancer.healthcheck.port=42"
- "traefik.http.services.service1.loadbalancer.healthcheck.scheme=foobar"
- "traefik.http.services.service1.loadbalancer.healthcheck.timeout=foobar"
- "traefik.http.services.service1.loadbalancer.passhostheader=true"
- "traefik.http.services.service1.loadbalancer.responseforwarding.flushinterval=foobar"
- "traefik.http.services.service1.loadbalancer.stickiness=true"
- "traefik.http.services.service1.loadbalancer.stickiness.cookiename=foobar"
- "traefik.http.services.service1.loadbalancer.stickiness.httponlycookie=true"
- "traefik.http.services.service1.loadbalancer.stickiness.securecookie=true"
- "traefik.http.services.service1.loadbalancer.server.port=foobar"
- "traefik.http.services.service1.loadbalancer.server.scheme=foobar"
- "traefik.tcp.routers.tcprouter0.entrypoints=foobar, foobar"
- "traefik.tcp.routers.tcprouter0.rule=foobar"
- "traefik.tcp.routers.tcprouter0.service=foobar"
- "traefik.tcp.routers.tcprouter0.tls=true"
- "traefik.tcp.routers.tcprouter0.tls.options=foobar"
- "traefik.tcp.routers.tcprouter0.tls.passthrough=true"
- "traefik.tcp.routers.tcprouter1.entrypoints=foobar, foobar"
- "traefik.tcp.routers.tcprouter1.rule=foobar"
- "traefik.tcp.routers.tcprouter1.service=foobar"
- "traefik.tcp.routers.tcprouter1.tls=true"
- "traefik.tcp.routers.tcprouter1.tls.options=foobar"
- "traefik.tcp.routers.tcprouter1.tls.passthrough=true"
- "traefik.tcp.services.tcpservice0.loadbalancer.server.port=foobar"
- "traefik.tcp.services.tcpservice1.loadbalancer.server.port=foobar"

View file

@ -0,0 +1,177 @@
"traefik.http.middlewares.middleware00.addprefix.prefix": "foobar",
"traefik.http.middlewares.middleware01.basicauth.headerfield": "foobar",
"traefik.http.middlewares.middleware01.basicauth.realm": "foobar",
"traefik.http.middlewares.middleware01.basicauth.removeheader": "true",
"traefik.http.middlewares.middleware01.basicauth.users": "foobar, foobar",
"traefik.http.middlewares.middleware01.basicauth.usersfile": "foobar",
"traefik.http.middlewares.middleware02.buffering.maxrequestbodybytes": "42",
"traefik.http.middlewares.middleware02.buffering.maxresponsebodybytes": "42",
"traefik.http.middlewares.middleware02.buffering.memrequestbodybytes": "42",
"traefik.http.middlewares.middleware02.buffering.memresponsebodybytes": "42",
"traefik.http.middlewares.middleware02.buffering.retryexpression": "foobar",
"traefik.http.middlewares.middleware03.chain.middlewares": "foobar, foobar",
"traefik.http.middlewares.middleware04.circuitbreaker.expression": "foobar",
"traefik.http.middlewares.middleware05.compress": "true",
"traefik.http.middlewares.middleware06.digestauth.headerfield": "foobar",
"traefik.http.middlewares.middleware06.digestauth.realm": "foobar",
"traefik.http.middlewares.middleware06.digestauth.removeheader": "true",
"traefik.http.middlewares.middleware06.digestauth.users": "foobar, foobar",
"traefik.http.middlewares.middleware06.digestauth.usersfile": "foobar",
"traefik.http.middlewares.middleware07.errors.query": "foobar",
"traefik.http.middlewares.middleware07.errors.service": "foobar",
"traefik.http.middlewares.middleware07.errors.status": "foobar, foobar",
"traefik.http.middlewares.middleware08.forwardauth.address": "foobar",
"traefik.http.middlewares.middleware08.forwardauth.authresponseheaders": "foobar, foobar",
"traefik.http.middlewares.middleware08.forwardauth.tls.ca": "foobar",
"traefik.http.middlewares.middleware08.forwardauth.tls.caoptional": "true",
"traefik.http.middlewares.middleware08.forwardauth.tls.cert": "foobar",
"traefik.http.middlewares.middleware08.forwardauth.tls.insecureskipverify": "true",
"traefik.http.middlewares.middleware08.forwardauth.tls.key": "foobar",
"traefik.http.middlewares.middleware08.forwardauth.trustforwardheader": "true",
"traefik.http.middlewares.middleware09.headers.accesscontrolallowcredentials": "true",
"traefik.http.middlewares.middleware09.headers.accesscontrolallowheaders": "foobar, foobar",
"traefik.http.middlewares.middleware09.headers.accesscontrolallowmethods": "foobar, foobar",
"traefik.http.middlewares.middleware09.headers.accesscontrolalloworigin": "foobar",
"traefik.http.middlewares.middleware09.headers.accesscontrolexposeheaders": "foobar, foobar",
"traefik.http.middlewares.middleware09.headers.accesscontrolmaxage": "42",
"traefik.http.middlewares.middleware09.headers.addvaryheader": "true",
"traefik.http.middlewares.middleware09.headers.allowedhosts": "foobar, foobar",
"traefik.http.middlewares.middleware09.headers.browserxssfilter": "true",
"traefik.http.middlewares.middleware09.headers.contentsecuritypolicy": "foobar",
"traefik.http.middlewares.middleware09.headers.contenttypenosniff": "true",
"traefik.http.middlewares.middleware09.headers.custombrowserxssvalue": "foobar",
"traefik.http.middlewares.middleware09.headers.customframeoptionsvalue": "foobar",
"traefik.http.middlewares.middleware09.headers.customrequestheaders.name0": "foobar",
"traefik.http.middlewares.middleware09.headers.customrequestheaders.name1": "foobar",
"traefik.http.middlewares.middleware09.headers.customresponseheaders.name0": "foobar",
"traefik.http.middlewares.middleware09.headers.customresponseheaders.name1": "foobar",
"traefik.http.middlewares.middleware09.headers.forcestsheader": "true",
"traefik.http.middlewares.middleware09.headers.framedeny": "true",
"traefik.http.middlewares.middleware09.headers.hostsproxyheaders": "foobar, foobar",
"traefik.http.middlewares.middleware09.headers.isdevelopment": "true",
"traefik.http.middlewares.middleware09.headers.publickey": "foobar",
"traefik.http.middlewares.middleware09.headers.referrerpolicy": "foobar",
"traefik.http.middlewares.middleware09.headers.sslforcehost": "true",
"traefik.http.middlewares.middleware09.headers.sslhost": "foobar",
"traefik.http.middlewares.middleware09.headers.sslproxyheaders.name0": "foobar",
"traefik.http.middlewares.middleware09.headers.sslproxyheaders.name1": "foobar",
"traefik.http.middlewares.middleware09.headers.sslredirect": "true",
"traefik.http.middlewares.middleware09.headers.ssltemporaryredirect": "true",
"traefik.http.middlewares.middleware09.headers.stsincludesubdomains": "true",
"traefik.http.middlewares.middleware09.headers.stspreload": "true",
"traefik.http.middlewares.middleware09.headers.stsseconds": "42",
"traefik.http.middlewares.middleware10.ipwhitelist.ipstrategy.depth": "42",
"traefik.http.middlewares.middleware10.ipwhitelist.ipstrategy.excludedips": "foobar, foobar",
"traefik.http.middlewares.middleware10.ipwhitelist.sourcerange": "foobar, foobar",
"traefik.http.middlewares.middleware11.maxconn.amount": "42",
"traefik.http.middlewares.middleware11.maxconn.extractorfunc": "foobar",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.commonname": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.country": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.domaincomponent": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.locality": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.organization": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.province": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.issuer.serialnumber": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.notafter": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.notbefore": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.sans": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.commonname": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.country": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.domaincomponent": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.locality": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.organization": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.province": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.info.subject.serialnumber": "true",
"traefik.http.middlewares.middleware12.passtlsclientcert.pem": "true",
"traefik.http.middlewares.middleware13.redirectregex.permanent": "true",
"traefik.http.middlewares.middleware13.redirectregex.regex": "foobar",
"traefik.http.middlewares.middleware13.redirectregex.replacement": "foobar",
"traefik.http.middlewares.middleware14.redirectscheme.permanent": "true",
"traefik.http.middlewares.middleware14.redirectscheme.port": "foobar",
"traefik.http.middlewares.middleware14.redirectscheme.scheme": "foobar",
"traefik.http.middlewares.middleware15.replacepath.path": "foobar",
"traefik.http.middlewares.middleware16.replacepathregex.regex": "foobar",
"traefik.http.middlewares.middleware16.replacepathregex.replacement": "foobar",
"traefik.http.middlewares.middleware17.retry.attempts": "42",
"traefik.http.middlewares.middleware18.stripprefix.prefixes": "foobar, foobar",
"traefik.http.middlewares.middleware19.stripprefixregex.regex": "foobar, foobar",
"traefik.http.routers.router0.entrypoints": "foobar, foobar",
"traefik.http.routers.router0.middlewares": "foobar, foobar",
"traefik.http.routers.router0.priority": "42",
"traefik.http.routers.router0.rule": "foobar",
"traefik.http.routers.router0.service": "foobar",
"traefik.http.routers.router0.tls": "true",
"traefik.http.routers.router0.tls.certresolver": "foobar",
"traefik.http.routers.router0.tls.domains[0].main": "foobar",
"traefik.http.routers.router0.tls.domains[0].sans": "foobar, foobar",
"traefik.http.routers.router0.tls.domains[1].main": "foobar",
"traefik.http.routers.router0.tls.domains[1].sans": "foobar, foobar",
"traefik.http.routers.router0.tls.options": "foobar",
"traefik.http.routers.router1.entrypoints": "foobar, foobar",
"traefik.http.routers.router1.middlewares": "foobar, foobar",
"traefik.http.routers.router1.priority": "42",
"traefik.http.routers.router1.rule": "foobar",
"traefik.http.routers.router1.service": "foobar",
"traefik.http.routers.router1.tls": "true",
"traefik.http.routers.router1.tls.certresolver": "foobar",
"traefik.http.routers.router1.tls.domains[0].main": "foobar",
"traefik.http.routers.router1.tls.domains[0].sans": "foobar, foobar",
"traefik.http.routers.router1.tls.domains[1].main": "foobar",
"traefik.http.routers.router1.tls.domains[1].sans": "foobar, foobar",
"traefik.http.routers.router1.tls.options": "foobar",
"traefik.http.services.service0.loadbalancer.healthcheck.headers.name0": "foobar",
"traefik.http.services.service0.loadbalancer.healthcheck.headers.name1": "foobar",
"traefik.http.services.service0.loadbalancer.healthcheck.hostname": "foobar",
"traefik.http.services.service0.loadbalancer.healthcheck.interval": "foobar",
"traefik.http.services.service0.loadbalancer.healthcheck.path": "foobar",
"traefik.http.services.service0.loadbalancer.healthcheck.port": "42",
"traefik.http.services.service0.loadbalancer.healthcheck.scheme": "foobar",
"traefik.http.services.service0.loadbalancer.healthcheck.timeout": "foobar",
"traefik.http.services.service0.loadbalancer.passhostheader": "true",
"traefik.http.services.service0.loadbalancer.responseforwarding.flushinterval": "foobar",
"traefik.http.services.service0.loadbalancer.stickiness": "true",
"traefik.http.services.service0.loadbalancer.stickiness.cookiename": "foobar",
"traefik.http.services.service0.loadbalancer.stickiness.httponlycookie": "true",
"traefik.http.services.service0.loadbalancer.stickiness.securecookie": "true",
"traefik.http.services.service0.loadbalancer.server.port": "foobar",
"traefik.http.services.service0.loadbalancer.server.scheme": "foobar",
"traefik.http.services.service1.loadbalancer.healthcheck.headers.name0": "foobar",
"traefik.http.services.service1.loadbalancer.healthcheck.headers.name1": "foobar",
"traefik.http.services.service1.loadbalancer.healthcheck.hostname": "foobar",
"traefik.http.services.service1.loadbalancer.healthcheck.interval": "foobar",
"traefik.http.services.service1.loadbalancer.healthcheck.path": "foobar",
"traefik.http.services.service1.loadbalancer.healthcheck.port": "42",
"traefik.http.services.service1.loadbalancer.healthcheck.scheme": "foobar",
"traefik.http.services.service1.loadbalancer.healthcheck.timeout": "foobar",
"traefik.http.services.service1.loadbalancer.passhostheader": "true",
"traefik.http.services.service1.loadbalancer.responseforwarding.flushinterval": "foobar",
"traefik.http.services.service1.loadbalancer.stickiness": "true",
"traefik.http.services.service1.loadbalancer.stickiness.cookiename": "foobar",
"traefik.http.services.service1.loadbalancer.stickiness.httponlycookie": "true",
"traefik.http.services.service1.loadbalancer.stickiness.securecookie": "true",
"traefik.http.services.service1.loadbalancer.server.port": "foobar",
"traefik.http.services.service1.loadbalancer.server.scheme": "foobar",
"traefik.tcp.routers.tcprouter0.entrypoints": "foobar, foobar",
"traefik.tcp.routers.tcprouter0.rule": "foobar",
"traefik.tcp.routers.tcprouter0.service": "foobar",
"traefik.tcp.routers.tcprouter0.tls": "true",
"traefik.tcp.routers.tcprouter0.tls.certresolver": "foobar",
"traefik.tcp.routers.tcprouter0.tls.domains[0].main": "foobar",
"traefik.tcp.routers.tcprouter0.tls.domains[0].sans": "foobar, foobar",
"traefik.tcp.routers.tcprouter0.tls.domains[1].main": "foobar",
"traefik.tcp.routers.tcprouter0.tls.domains[1].sans": "foobar, foobar",
"traefik.tcp.routers.tcprouter0.tls.options": "foobar",
"traefik.tcp.routers.tcprouter0.tls.passthrough": "true",
"traefik.tcp.routers.tcprouter1.entrypoints": "foobar, foobar",
"traefik.tcp.routers.tcprouter1.rule": "foobar",
"traefik.tcp.routers.tcprouter1.service": "foobar",
"traefik.tcp.routers.tcprouter1.tls": "true",
"traefik.tcp.routers.tcprouter1.tls.certresolver": "foobar",
"traefik.tcp.routers.tcprouter1.tls.domains[0].main": "foobar",
"traefik.tcp.routers.tcprouter1.tls.domains[0].sans": "foobar, foobar",
"traefik.tcp.routers.tcprouter1.tls.domains[1].main": "foobar",
"traefik.tcp.routers.tcprouter1.tls.domains[1].sans": "foobar, foobar",
"traefik.tcp.routers.tcprouter1.tls.options": "foobar",
"traefik.tcp.routers.tcprouter1.tls.passthrough": "true",
"traefik.tcp.services.tcpservice0.loadbalancer.server.port": "foobar",
"traefik.tcp.services.tcpservice1.loadbalancer.server.port": "foobar"

View file

@ -0,0 +1,2 @@
"traefik.enable": "true",
"traefik.marathon.ipaddressidx": "42",

View file

@ -3,8 +3,9 @@
Dynamic configuration with Marathon Labels
{: .subtitle }
```yaml
labels:
--8<-- "content/reference/dynamic-configuration/marathon.yml"
--8<-- "content/reference/dynamic-configuration/labels.yml"
```json
"labels": {
--8<-- "content/reference/dynamic-configuration/marathon.json"
--8<-- "content/reference/dynamic-configuration/marathon-labels.json"
}
```

View file

@ -1,2 +0,0 @@
- "traefik.enable=true"
- "traefik.marathon.ipaddressidx=42"

View file

@ -0,0 +1,12 @@
# Rancher Configuration Reference
Dynamic configuration with Rancher Labels
{: .subtitle }
The labels are case insensitive.
```yaml
labels:
--8<-- "content/reference/dynamic-configuration/rancher.yml"
--8<-- "content/reference/dynamic-configuration/docker-labels.yml"
```

View file

@ -0,0 +1 @@
- "traefik.enable=true"

View file

@ -96,7 +96,6 @@
labelSelector = "foobar"
ingressClass = "foobar"
[providers.rest]
entryPoint = "foobar"
[providers.rancher]
constraints = "foobar"
watch = true
@ -108,18 +107,12 @@
prefix = "foobar"
[api]
entryPoint = "foobar"
dashboard = true
debug = true
middlewares = ["foobar", "foobar"]
[api.statistics]
recentErrors = 42
[metrics]
[metrics.prometheus]
buckets = [42.0, 42.0]
entryPoint = "foobar"
middlewares = ["foobar", "foobar"]
addEntryPointsLabels = true
addServicesLabels = true
[metrics.dataDog]
@ -144,8 +137,6 @@
addServicesLabels = true
[ping]
entryPoint = "foobar"
middlewares = ["foobar", "foobar"]
[log]
level = "foobar"
@ -219,25 +210,32 @@
resolvConfig = "foobar"
resolvDepth = 42
[acme]
email = "foobar"
caServer = "foobar"
storage = "foobar"
entryPoint = "foobar"
keyType = "foobar"
[acme.dnsChallenge]
provider = "foobar"
delayBeforeCheck = 42
resolvers = ["foobar", "foobar"]
disablePropagationCheck = true
[acme.httpChallenge]
entryPoint = "foobar"
[acme.tlsChallenge]
[[acme.domains]]
main = "foobar"
sans = ["foobar", "foobar"]
[[acme.domains]]
main = "foobar"
sans = ["foobar", "foobar"]
[certificatesResolvers]
[certificatesResolvers.CertificateResolver0]
[certificatesResolvers.CertificateResolver0.acme]
email = "foobar"
caServer = "foobar"
storage = "foobar"
keyType = "foobar"
[certificatesResolvers.CertificateResolver0.acme.dnsChallenge]
provider = "foobar"
delayBeforeCheck = 42
resolvers = ["foobar", "foobar"]
disablePropagationCheck = true
[certificatesResolvers.CertificateResolver0.acme.httpChallenge]
entryPoint = "foobar"
[certificatesResolvers.CertificateResolver0.acme.tlsChallenge]
[certificatesResolvers.CertificateResolver1]
[certificatesResolvers.CertificateResolver1.acme]
email = "foobar"
caServer = "foobar"
storage = "foobar"
keyType = "foobar"
[certificatesResolvers.CertificateResolver1.acme.dnsChallenge]
provider = "foobar"
delayBeforeCheck = 42
resolvers = ["foobar", "foobar"]
disablePropagationCheck = true
[certificatesResolvers.CertificateResolver1.acme.httpChallenge]
entryPoint = "foobar"
[certificatesResolvers.CertificateResolver1.acme.tlsChallenge]

View file

@ -102,8 +102,7 @@ providers:
- foobar
labelSelector: foobar
ingressClass: foobar
rest:
entryPoint: foobar
rest: {}
rancher:
constraints: foobar
watch: true
@ -114,23 +113,13 @@ providers:
intervalPoll: true
prefix: foobar
api:
entryPoint: foobar
dashboard: true
debug: true
statistics:
recentErrors: 42
middlewares:
- foobar
- foobar
metrics:
prometheus:
buckets:
- 42
- 42
entryPoint: foobar
middlewares:
- foobar
- foobar
addEntryPointsLabels: true
addServicesLabels: true
dataDog:
@ -153,11 +142,7 @@ metrics:
password: foobar
addEntryPointsLabels: true
addServicesLabels: true
ping:
entryPoint: foobar
middlewares:
- foobar
- foobar
ping: {}
log:
level: foobar
filePath: foobar
@ -228,28 +213,36 @@ hostResolver:
cnameFlattening: true
resolvConfig: foobar
resolvDepth: 42
acme:
email: foobar
caServer: foobar
storage: foobar
entryPoint: foobar
keyType: foobar
dnsChallenge:
provider: foobar
delayBeforeCheck: 42
resolvers:
- foobar
- foobar
disablePropagationCheck: true
httpChallenge:
entryPoint: foobar
tlsChallenge: {}
domains:
- main: foobar
sans:
- foobar
- foobar
- main: foobar
sans:
- foobar
- foobar
certificatesResolvers:
CertificateResolver0:
acme:
email: foobar
caServer: foobar
storage: foobar
keyType: foobar
dnsChallenge:
provider: foobar
delayBeforeCheck: 42
resolvers:
- foobar
- foobar
disablePropagationCheck: true
httpChallenge:
entryPoint: foobar
tlsChallenge: {}
CertificateResolver1:
acme:
email: foobar
caServer: foobar
storage: foobar
keyType: foobar
dnsChallenge:
provider: foobar
delayBeforeCheck: 42
resolvers:
- foobar
- foobar
disablePropagationCheck: true
httpChallenge:
entryPoint: foobar
tlsChallenge: {}

View file

@ -288,10 +288,6 @@ Traefik will terminate the SSL connections (meaning that it will send decrypted
In the current version, with [ACME](../../https/acme.md) enabled, automatic certificate generation will apply to every router declaring a TLS section.
!!! note "Passthrough"
On TCP routers, you can configure a passthrough option so that Traefik doesn't terminate the TLS connection.
!!! important "Routers for HTTP & HTTPS"
If you need to define the same route for both HTTP and HTTPS requests, you will need to define two different routers: one with the tls section, one without.
@ -463,7 +459,7 @@ http:
```
[ACME v2](https://community.letsencrypt.org/t/acme-v2-and-wildcard-certificate-support-is-live/55579) supports wildcard certificates.
As described in [Let's Encrypt's post](https://community.letsencrypt.org/t/staging-endpoint-for-acme-v2/49605) wildcard certificates can only be generated through a [`DNS-01` challenge](./../../https/acme.md#dnschallenge).
As described in [Let's Encrypt's post](https://community.letsencrypt.org/t/staging-endpoint-for-acme-v2/49605) wildcard certificates can only be generated through a [`DNS-01` challenge](../../https/acme.md#dnschallenge).
Most likely the root domain should receive a certificate too, so it needs to be specified as SAN and 2 `DNS-01` challenges are executed.
In this case the generated DNS TXT record for both domains is the same.
@ -471,10 +467,10 @@ Even though this behavior is [DNS RFC](https://community.letsencrypt.org/t/wildc
it can lead to problems as all DNS providers keep DNS records cached for a given time (TTL) and this TTL can be greater than the challenge timeout making the `DNS-01` challenge fail.
The Traefik ACME client library [LEGO](https://github.com/go-acme/lego) supports some but not all DNS providers to work around this issue.
The [Supported `provider` table](./../../https/acme.md#providers) indicates if they allow generating certificates for a wildcard domain and its root domain.
The [Supported `provider` table](../../https/acme.md#providers) indicates if they allow generating certificates for a wildcard domain and its root domain.
!!! note
Wildcard certificates can only be verified through a `DNS-01` challenge.
Wildcard certificates can only be verified through a [`DNS-01` challenge](../../https/acme.md#dnschallenge).
!!! note "Double Wildcard Certificates"
It is not possible to request a double wildcard certificate for a domain (for example `*.*.local.com`).

View file

@ -34,7 +34,7 @@ api: {}
```yaml tab="CLI"
--entryPoints.web.address=":80"
--providers.file.filename=dynamic_conf.toml
--api
--api=true
```
`dynamic_conf.{toml,yml}`:
@ -157,7 +157,7 @@ api: {}
# For secure connection on backend.local
--serversTransport.rootCAs=./backend.cert
--providers.file.filename=dynamic_conf.toml
--api
--api=true
```
`dynamic_conf.{toml,yml}`:

View file

@ -146,7 +146,7 @@ nav:
- 'Data Collection': 'contributing/data-collection.md'
- 'Advocating': 'contributing/advocating.md'
- 'Maintainers': 'contributing/maintainers.md'
- 'Glossary': 'glossary.md'
# - 'Glossary': 'glossary.md'
- 'References':
- 'Static Configuration':
- 'Overview': 'reference/static-configuration/overview.md'
@ -154,7 +154,8 @@ nav:
- 'CLI': 'reference/static-configuration/cli.md'
- 'Environment variables': 'reference/static-configuration/env.md'
- 'Dynamic Configuration':
- 'Docker': 'reference/dynamic-configuration/docker.md'
- 'Marathon': 'reference/dynamic-configuration/marathon.md'
- 'Kubernetes CRD': 'reference/dynamic-configuration/kubernetes-crd.md'
- 'File': 'reference/dynamic-configuration/file.md'
- 'Docker': 'reference/dynamic-configuration/docker.md'
- 'Kubernetes CRD': 'reference/dynamic-configuration/kubernetes-crd.md'
- 'Marathon': 'reference/dynamic-configuration/marathon.md'
- 'Rancher': 'reference/dynamic-configuration/rancher.md'

View file

@ -1,6 +1,7 @@
################################################################
#
# Configuration sample for Traefik v2
# Configuration sample for Traefik v2.
#
# For Traefik v1: https://github.com/containous/traefik/blob/v1.7/traefik.sample.toml
#
################################################################
@ -22,7 +23,10 @@
# Default:
[entryPoints]
[entryPoints.web]
address = ":80"
address = ":80"
[entryPoints.websecure]
address = ":443"
################################################################
# Traefik logs configuration
@ -35,27 +39,27 @@
#
[log]
# Log level
#
# Optional
# Default: "ERROR"
#
# level = "DEBUG"
# Log level
#
# Optional
# Default: "ERROR"
#
# level = "DEBUG"
# Sets the filepath for the traefik log. If not specified, stdout will be used.
# Intermediate directories are created if necessary.
#
# Optional
# Default: os.Stdout
#
# filePath = "log/traefik.log"
# Sets the filepath for the traefik log. If not specified, stdout will be used.
# Intermediate directories are created if necessary.
#
# Optional
# Default: os.Stdout
#
# filePath = "log/traefik.log"
# Format is either "json" or "common".
#
# Optional
# Default: "common"
#
# format = "common"
# Format is either "json" or "common".
#
# Optional
# Default: "common"
#
# format = "json"
################################################################
# Access logs configuration
@ -69,20 +73,20 @@
#
# [accessLog]
# Sets the file path for the access log. If not specified, stdout will be used.
# Intermediate directories are created if necessary.
#
# Optional
# Default: os.Stdout
#
# filePath = "/path/to/log/log.txt"
# Sets the file path for the access log. If not specified, stdout will be used.
# Intermediate directories are created if necessary.
#
# Optional
# Default: os.Stdout
#
# filePath = "/path/to/log/log.txt"
# Format is either "json" or "common".
#
# Optional
# Default: "common"
#
# format = "common"
# Format is either "json" or "common".
#
# Optional
# Default: "common"
#
# format = "json"
################################################################
# API and dashboard configuration
@ -126,23 +130,23 @@
# Enable Docker configuration backend
[providers.docker]
# Docker server endpoint. Can be a tcp or a unix socket endpoint.
#
# Required
# Default: "unix:///var/run/docker.sock"
#
# endpoint = "tcp://10.10.10.10:2375"
# Docker server endpoint. Can be a tcp or a unix socket endpoint.
#
# Required
# Default: "unix:///var/run/docker.sock"
#
# endpoint = "tcp://10.10.10.10:2375"
# Default host rule.
#
# Optional
# Default: ""
#
# DefaultRule = "Host(`{{ normalize .Name }}.docker.localhost`)"
# Default host rule.
#
# Optional
# Default: "Host(`{{ normalize .Name }}`)"
#
# defaultRule = "Host(`{{ normalize .Name }}.docker.localhost`)"
# Expose containers by default in traefik
#
# Optional
# Default: true
#
# exposedByDefault = true
# Expose containers by default in traefik
#
# Optional
# Default: true
#
# exposedByDefault = false