diff options
author | pmikus <pmikus@cisco.com> | 2021-01-07 14:27:38 +0000 |
---|---|---|
committer | pmikus <pmikus@cisco.com> | 2021-01-29 08:44:37 +0000 |
commit | a44eef233de959c5679602dc6cd1ed866d6abc14 (patch) | |
tree | 2c4d0cd5e0d1293ae86a09cf26009b869c72360d /terraform-ci-infra/1n_nmd/grafana/main.tf | |
parent | 474163bc78aa418595b227c81056987b1114104d (diff) |
Infra: Monitoring capability
+ Monitoring SOA
+ Nomad alertmanager job
+ Nomad prometheus job
+ Nomad grafana job
Signed-off-by: pmikus <pmikus@cisco.com>
Change-Id: I0b32e9c87276ba1a2d4a5322816f3473c737eae2
Diffstat (limited to 'terraform-ci-infra/1n_nmd/grafana/main.tf')
-rw-r--r-- | terraform-ci-infra/1n_nmd/grafana/main.tf | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/terraform-ci-infra/1n_nmd/grafana/main.tf b/terraform-ci-infra/1n_nmd/grafana/main.tf new file mode 100644 index 0000000000..b67ba03985 --- /dev/null +++ b/terraform-ci-infra/1n_nmd/grafana/main.tf @@ -0,0 +1,24 @@ +locals { + datacenters = join(",", var.nomad_datacenters) +} + +data "template_file" "nomad_job_grafana" { + template = file("${path.module}/conf/nomad/grafana.hcl") + vars = { + datacenters = local.datacenters + job_name = var.grafana_job_name + use_canary = var.grafana_use_canary + group_count = var.grafana_group_count + service_name = var.grafana_service_name + use_vault_provider = var.grafana_vault_secret.use_vault_provider + image = var.grafana_container_image + cpu = var.grafana_cpu + mem = var.grafana_mem + port = var.grafana_port + } +} + +resource "nomad_job" "nomad_job_grafana" { + jobspec = data.template_file.nomad_job_grafana.rendered + detach = false +}
\ No newline at end of file |