| 1 | amends "../../config/Service.pkl" |
| 2 | |
| 3 | name = "Ingest" |
| 4 | tagline = "Logs and metrics pushed from the VPS" |
| 5 | launcher = false |
| 6 | dependsOn { "victoria" } |
| 7 | |
| 8 | secrets { ["token"] {} } |
| 9 | |
| 10 | container { |
| 11 | build = "build" |
| 12 | readOnlyRoot = true |
| 13 | cpu = 100 |
| 14 | memory = 128 |
| 15 | |
| 16 | http { |
| 17 | containerPort = 8000 |
| 18 | subdomain = "ingest" |
| 19 | checkPath = "/health" |
| 20 | } |
| 21 | |
| 22 | env { |
| 23 | ["INGEST_TOKEN"] = "${secret.own.token}" |
| 24 | } |
| 25 | |
| 26 | envTemplate = """ |
| 27 | {{ range nomadService 1 (env "NOMAD_ALLOC_ID") "victoria-logs" }}LOGS_URL=http://\(module.nomadHostPort){{ end }} |
| 28 | {{ range nomadService 1 (env "NOMAD_ALLOC_ID") "victoria-metrics" }}METRICS_URL=http://\(module.nomadHostPort){{ end }} |
| 29 | """ |
| 30 | } |