add http headers to healthcheck

This commit is contained in:
Jesse Haka 2018-04-16 11:40:03 +02:00 committed by Traefiker Bot
parent de3aeb9732
commit 1954a49f37
29 changed files with 337 additions and 64 deletions

View file

@ -424,6 +424,20 @@ To use a different port for the healthcheck:
port = 8080
```
Additional http headers and hostname to healthcheck request can be specified, for instance:
```toml
[backends]
[backends.backend1]
[backends.backend1.healthcheck]
path = "/health"
interval = "10s"
hostname = "myhost.com"
port = 8080
[backends.backend1.healthcheck.headers]
mycustomheader = "foo"
myheader2 = "bar"
```
### Servers
Servers are simply defined using a `url`. You can also apply a custom `weight` to each server (this will be used by load-balancing).