job "syslogng" { datacenters = ["dc1"] type = "service" group "promtail" { count = 1 network { mode = "bridge" port "main" { to = 1514 } port "metrics" { to = 9080 } } service { name = "syslogng-promtail" port = "main" connect { sidecar_service { proxy { local_service_port = 1514 upstreams { destination_name = "loki" local_bind_port = 1000 } } } sidecar_task { resources { cpu = 50 memory = 20 memory_max = 50 } } } } task "promtail" { driver = "docker" meta = { "diun.sort_tags" = "semver" "diun.watch_repo" = true "diun.include_tags" = "^[0-9]+\\.[0-9]+\\.[0-9]+" } config { image = "grafana/promtail:2.7.1" ports = ["main", "metrics"] args = ["--config.file=/etc/promtail/promtail.yml"] mount { type = "bind" target = "/etc/promtail/promtail.yml" source = "local/promtail.yml" } } template { data = <