chore(dummy): onboard to traefiks connect-enabled provider
This commit is contained in:
parent
c6b078cb2d
commit
0b3293d65e
1 changed files with 28 additions and 11 deletions
|
@ -1,8 +1,15 @@
|
||||||
job "hello-world" {
|
job "hello-world" {
|
||||||
datacenters = ["dc1"]
|
|
||||||
|
|
||||||
group "servers" {
|
group "servers" {
|
||||||
count = 1
|
|
||||||
|
network {
|
||||||
|
mode = "bridge"
|
||||||
|
port "www" {
|
||||||
|
to = 8001
|
||||||
|
}
|
||||||
|
port "envoy_metrics" {
|
||||||
|
to = 9102
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
task "web" {
|
task "web" {
|
||||||
driver = "docker"
|
driver = "docker"
|
||||||
|
@ -25,20 +32,30 @@ job "hello-world" {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
network {
|
|
||||||
mode = "bridge"
|
|
||||||
port "www" {
|
|
||||||
to = 8001
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
service {
|
service {
|
||||||
port = "www"
|
port = 8001
|
||||||
provider = "consul"
|
provider = "consul"
|
||||||
|
|
||||||
|
connect {
|
||||||
|
sidecar_service {
|
||||||
|
proxy {
|
||||||
|
expose {
|
||||||
|
path {
|
||||||
|
path = "/metrics"
|
||||||
|
protocol = "http"
|
||||||
|
local_path_port = 9102
|
||||||
|
listener_port = "envoy_metrics"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
transparent_proxy {}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
tags = [
|
tags = [
|
||||||
"traefik.enable=true",
|
"traefik.enable=true",
|
||||||
"traefik.http.routers.web.rule=Host(`hello-world.brmartin.co.uk`)",
|
"traefik.http.routers.web.rule=Host(`hello-world.brmartin.co.uk`)",
|
||||||
|
"traefik.consulcatalog.connect=true",
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue