Grafana config.
This commit is contained in:
57
services/grafana.hcl
Normal file
57
services/grafana.hcl
Normal file
@@ -0,0 +1,57 @@
|
||||
job "grafana" {
|
||||
datacenters = ["alo"]
|
||||
|
||||
group "monitoring" {
|
||||
network {
|
||||
port "http" {
|
||||
host_network = "tailscale"
|
||||
}
|
||||
}
|
||||
|
||||
volume "data-volume" {
|
||||
type = "csi"
|
||||
source = "grafana-data"
|
||||
access_mode = "single-node-writer"
|
||||
attachment_mode = "file-system"
|
||||
}
|
||||
|
||||
task "grafana" {
|
||||
driver = "docker"
|
||||
|
||||
config {
|
||||
image = "grafana/grafana-enterprise"
|
||||
ports = [ "http" ]
|
||||
}
|
||||
|
||||
env {
|
||||
GF_AUTH_BASIC_ENABLED = "false"
|
||||
GF_SERVER_HTTP_PORT = "${NOMAD_PORT_http}"
|
||||
}
|
||||
|
||||
volume_mount {
|
||||
volume = "data-volume"
|
||||
destination = "/var/lib/grafana"
|
||||
}
|
||||
|
||||
service {
|
||||
port = "http"
|
||||
name = "grafana"
|
||||
tags = [
|
||||
"traefik.enable=true",
|
||||
"traefik.http.routers.grafana.entryPoints=websecure",
|
||||
]
|
||||
check {
|
||||
type = "http"
|
||||
path = "/"
|
||||
interval = "10s"
|
||||
timeout = "2s"
|
||||
}
|
||||
}
|
||||
|
||||
resources {
|
||||
cpu = 100
|
||||
memory = 128
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user