migrate grafana to mysql from sqlite [ci skip]

This commit is contained in:
Viktor Barzin 2025-12-27 20:51:05 +00:00
parent 221154aa9c
commit f06e050eaa
5 changed files with 15774 additions and 1997 deletions

View file

@ -127,6 +127,7 @@ variable "tiny_tuya_service_secret" { type = string }
variable "tiny_tuya_slack_url" { type = string }
variable "haos_api_token" { type = string }
variable "pve_password" { type = string }
variable "grafana_db_password" { type = string }
variable "clickhouse_password" { type = string }
variable "clickhouse_postgres_password" { type = string }
variable "wealthfolio_password_hash" { type = string }
@ -522,6 +523,7 @@ module "kubernetes_cluster" {
tiny_tuya_slack_url = var.tiny_tuya_slack_url
haos_api_token = var.haos_api_token
pve_password = var.pve_password
grafana_db_password = var.grafana_db_password
clickhouse_password = var.clickhouse_password
clickhouse_postgres_password = var.clickhouse_postgres_password

View file

@ -106,6 +106,7 @@ variable "tiny_tuya_service_secret" { type = string }
variable "tiny_tuya_slack_url" { type = string }
variable "haos_api_token" { type = string }
variable "pve_password" { type = string }
variable "grafana_db_password" { type = string }
variable "clickhouse_password" { type = string }
variable "clickhouse_postgres_password" { type = string }
variable "wealthfolio_password_hash" { type = string }
@ -247,6 +248,7 @@ module "monitoring" {
tiny_tuya_service_secret = var.tiny_tuya_service_secret
haos_api_token = var.haos_api_token
pve_password = var.pve_password
grafana_db_password = var.grafana_db_password
depends_on = [null_resource.core_services]
}

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff

View file

@ -13,6 +13,7 @@ variable "alertmanager_slack_api_url" {}
variable "tiny_tuya_service_secret" { type = string }
variable "haos_api_token" { type = string }
variable "pve_password" { type = string }
variable "grafana_db_password" { type = string }
module "tls_secret" {
source = "../setup_tls_secret"
@ -222,7 +223,7 @@ resource "helm_release" "grafana" {
repository = "https://grafana.github.io/helm-charts"
chart = "grafana"
values = [file("${path.module}/grafana_chart_values.yaml")]
values = [templatefile("${path.module}/grafana_chart_values.yaml", { db_password = var.grafana_db_password })]
}
resource "kubernetes_cron_job_v1" "monitor_prom" {