job "expose-custom" { datacenters = ["dc1"] constraint { attribute = "${attr.kernel.name}" value = "linux" } group "api" { network { mode = "bridge" } service { name = "count-api" port = "9001" connect { sidecar_service {} sidecar_task { resources { cpu = 133 memory = 63 } } } check { expose = true name = "api-health" type = "http" path = "/health" interval = "10s" timeout = "3s" } } task "web" { driver = "docker" config { image = "hashicorpdev/counter-api:v3" } } } }