Skip to content

Commit

Permalink
chore(promtail): retrieve artifact from the interweb
Browse files Browse the repository at this point in the history
Signed-off-by: Bruce Becker <[email protected]>
  • Loading branch information
brucellino committed May 30, 2022
1 parent 55f72bb commit 9ef4d60
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 11 deletions.
21 changes: 13 additions & 8 deletions promtail.nomad
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@ job "promtail" {
}
datacenters = ["dc1"]
type = "system"
// constraint {
// attribute = "${node.class}"
// operator = "regexp"
// value = "32|64"
// }
constraint {
attribute = "${node.class}"
operator = "regexp"
value = "64"
}

group "promtail" {
count = 1
Expand Down Expand Up @@ -78,10 +78,15 @@ job "promtail" {
args = ["-config.file=local/promtail.yml"]
}

// artifact {
// source = "http://minio-api.service.consul:9000/loki-bin/promtail-linux-${attr.cpu.arch}.zip"
// destination = "local/promtail"
// mode = "file"
// }
artifact {
source = "http://minio-api.service.consul:9000/loki-bin/promtail-linux-${attr.cpu.arch}.zip"
destination = "local/promtail"
mode = "file"
source = "https://github.com/grafana/loki/releases/download/v2.5.0/promtail-linux-arm64.zip"
destination = "local/promtail"
mode = "file"
}


Expand Down
6 changes: 3 additions & 3 deletions promtail.yml.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,14 @@ clients:
- url: http://loki-http-server.service.consul:3100/loki/api/v1/push

scrape_configs:
- job_name: system
- job_name: consul
static_configs:
- targets:
- localhost
labels:
job: consul
__path__: /var/log/consul*.log
- job_name: system
__path__: /home/consul/*.log
- job_name: nomad
static_configs:
- targets:
- localhost
Expand Down

0 comments on commit 9ef4d60

Please sign in to comment.