2024-06-07 19:15:23 +00:00
|
|
|
resource "juju_machine" "grafana" {
|
|
|
|
model = var.lma-model-name
|
|
|
|
placement = join(":", ["lxd", juju_machine.lma_machines["201"].machine_id])
|
|
|
|
constraints = "spaces=oam"
|
|
|
|
}
|
|
|
|
|
|
|
|
resource "juju_application" "grafana" {
|
|
|
|
name = "grafana"
|
|
|
|
|
|
|
|
model = var.lma-model-name
|
|
|
|
|
|
|
|
charm {
|
|
|
|
name = "grafana"
|
|
|
|
channel = "latest/stable"
|
|
|
|
base = "ubuntu@20.04"
|
|
|
|
}
|
|
|
|
|
|
|
|
units = 1
|
|
|
|
|
|
|
|
placement = juju_machine.grafana.machine_id
|
|
|
|
|
|
|
|
endpoint_bindings = [{
|
|
|
|
space = var.oam-space
|
|
|
|
}]
|
|
|
|
|
|
|
|
config = {
|
|
|
|
port = "3000"
|
|
|
|
install_method = "snap"
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2024-06-14 18:47:07 +00:00
|
|
|
resource "juju_offer" "grafana" {
|
|
|
|
model = var.lma-model-name
|
|
|
|
application_name = juju_application.grafana.name
|
|
|
|
endpoint = "dashboards"
|
|
|
|
}
|