Hi. Sure. Here's some information about the environment i'm running it in:
Small cluster with 3 Nomad servers and 2 workers in AWS behind an ALB. Worker nodes run Traefik on them.
Nomad 0.10.4
Consul 1.7.2
Traefik 2.1.4
Traefik Config:
[global]
checkNewVersion = false
sendAnonymousUsage = false
[entryPoints]
[entryPoints.http]
address = ":9999"
[entryPoints.http.forwardedHeaders]
insecure = true
[entryPoints.traefik]
address = ":9998"
[providers]
[providers.consulCatalog]
prefix = "traefik"
requireConsistent = true # Also tried with False here, no difference
exposedByDefault = false
[providers.consulCatalog.endpoint]
address = "http://127.0.0.1:8500"
scheme = "http"
[api]
insecure = true
dashboard = true
debug = true
[metrics]
[metrics.prometheus]
buckets = [0.1,0.3,0.5,1.0,1.5,5.0]
entryPoint = "traefik"
[ping]
entryPoint = "traefik"
[log]
level = "debug"
Nomad jobfile:
job "http-echo" {
region = "eu-central-1"
datacenters = ["eu-central-1"]
type = "service"
group "debug" {
count = 2
constraint {
operator = "distinct_hosts"
value = "true"
}
constraint {
#Place workload in different Availability Zones
distinct_property = "${attr.platform.aws.placement.availability-zone}"
}
update {
max_parallel = 1
min_healthy_time = "10s"
healthy_deadline = "5m"
}
task "http-echo" {
driver = "docker"
config {
image = "hashicorp/http-echo"
port_map {
echo = 5678
}
args = ["-text", "version2: ${node.unique.name}, ip: ${attr.unique.network.ip-address}"]
}
service {
name = "http-echo"
tags = [
"http-echo",
"traefik.enable=true",
"traefik.http.routers.http-echo.rule=Host(`new-test2.example.com`)",
]
port = "echo"
check {
type = "http"
path = "/"
interval = "5s"
timeout = "2s"
port = "echo"
}
}
resources {
cpu = 20
memory = 20
network {
port "echo" { }
}
}
}
}
}
Curl result during deploy (normally i run without sleep and it's no problem, not a single Bad Gateway. But added a sleep to not spam with too much unrelevant info:
while :; do echo -n $(date) " "; curl https://new-test2.example.com; sleep 0.5;done
Wed 04 Mar 2020 03:03:07 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:08 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:09 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:09 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:10 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:10 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:11 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:12 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:12 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:13 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:14 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:14 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:15 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:15 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:16 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:17 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:17 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:18 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:19 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:19 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:20 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:20 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:21 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:22 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:22 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:23 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:24 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:24 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:25 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:26 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:26 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:27 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:27 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:28 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:29 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:29 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:30 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:31 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:31 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:32 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:32 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:33 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:34 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:34 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:35 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:36 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:36 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:37 PM CET version1: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:37 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:38 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:39 PM CET Bad Gateway
Wed 04 Mar 2020 03:03:39 PM CET Bad Gateway
Wed 04 Mar 2020 03:03:40 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:41 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:41 PM CET Bad Gateway
Wed 04 Mar 2020 03:03:42 PM CET Bad Gateway
Wed 04 Mar 2020 03:03:42 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:43 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:44 PM CET Bad Gateway
Wed 04 Mar 2020 03:03:44 PM CET Bad Gateway
Wed 04 Mar 2020 03:03:45 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:46 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:46 PM CET Bad Gateway
Wed 04 Mar 2020 03:03:47 PM CET Bad Gateway
Wed 04 Mar 2020 03:03:48 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:48 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:49 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:50 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:50 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:51 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:51 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:52 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:53 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:53 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:54 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:55 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:55 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:56 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:57 PM CET version1: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:03:57 PM CET Bad Gateway
Wed 04 Mar 2020 03:03:58 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:58 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:03:59 PM CET Bad Gateway
Wed 04 Mar 2020 03:04:00 PM CET Bad Gateway
Wed 04 Mar 2020 03:04:00 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:04:01 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:04:02 PM CET Bad Gateway
Wed 04 Mar 2020 03:04:02 PM CET Bad Gateway
Wed 04 Mar 2020 03:04:03 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:04:03 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:04:04 PM CET version2: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:04:05 PM CET version2: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:04:05 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:04:06 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:04:07 PM CET version2: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:04:07 PM CET version2: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:04:08 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:04:08 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:04:09 PM CET version2: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:04:10 PM CET version2: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:04:10 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:04:11 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:04:12 PM CET version2: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:04:12 PM CET version2: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:04:13 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:04:13 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Wed 04 Mar 2020 03:04:14 PM CET version2: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:04:15 PM CET version2: ip-10-0-1-223, ip: 10.0.1.223
Wed 04 Mar 2020 03:04:15 PM CET version2: ip-10-0-3-139, ip: 10.0.3.139
Logs from 10.0.1.223
Logs from 10.0.3.139
Config that works on 1.7.19:
# traefik.toml
################################################################
# Global configuration
################################################################
[entryPoints]
[entryPoints.http]
address = ":9999"
[entryPoints.traefik_api]
address = ":9998"
[ping]
entryPoint = "traefik_api"
[api]
entryPoint = "traefik_api"
dashboard = true
debug = true
################################################################
# Consul Catalog configuration backend
################################################################
[consulCatalog]
endpoint = "127.0.0.1:8500"
domain = "service.consul"
prefix = "traefik"
watch = true
[metrics]
[metrics.prometheus]
entryPoint = "traefik_api"
buckets = [0.1,0.3,1.2,5.0]