diff --git a/terraform/gitops/generate-files/templates/mojaloop/grafana.yaml.tpl b/terraform/gitops/generate-files/templates/mojaloop/grafana.yaml.tpl index 34ac16dc4..65ac95845 100644 --- a/terraform/gitops/generate-files/templates/mojaloop/grafana.yaml.tpl +++ b/terraform/gitops/generate-files/templates/mojaloop/grafana.yaml.tpl @@ -21,7 +21,7 @@ spec: datasources: - inputName: "DS_PROMETHEUS" datasourceName: "Prometheus" - url: "https://raw.githubusercontent.com/mojaloop/helm/v${grafana_dashboard_tag}/monitoring/dashboards/mojaloop/dashboard-NodeJSApplication.json" + url: "https://raw.githubusercontent.com/mojaloop/helm/${grafana_dashboard_tag}/monitoring/dashboards/mojaloop/dashboard-NodeJSApplication.json" --- apiVersion: grafana.integreatly.org/v1beta1 kind: GrafanaDashboard @@ -36,7 +36,7 @@ spec: datasources: - inputName: "DS_PROMETHEUS" datasourceName: "Prometheus" - url: "https://raw.githubusercontent.com/mojaloop/helm/v${grafana_dashboard_tag}/monitoring/dashboards/mojaloop/dashboard-account-lookup-service.json" + url: "https://raw.githubusercontent.com/mojaloop/helm/${grafana_dashboard_tag}/monitoring/dashboards/mojaloop/dashboard-account-lookup-service.json" --- apiVersion: grafana.integreatly.org/v1beta1 kind: GrafanaDashboard @@ -51,7 +51,7 @@ spec: datasources: - inputName: "DS_PROMETHEUS" datasourceName: "Prometheus" - url: "https://raw.githubusercontent.com/mojaloop/helm/v${grafana_dashboard_tag}/monitoring/dashboards/mojaloop/dashboard-central-services-characterization.json" + url: "https://raw.githubusercontent.com/mojaloop/helm/${grafana_dashboard_tag}/monitoring/dashboards/mojaloop/dashboard-central-services-characterization.json" --- apiVersion: grafana.integreatly.org/v1beta1 kind: GrafanaDashboard @@ -66,7 +66,7 @@ spec: datasources: - inputName: "DS_PROMETHEUS" datasourceName: "Prometheus" - url: "https://raw.githubusercontent.com/mojaloop/helm/v${grafana_dashboard_tag}/monitoring/dashboards/mojaloop/dashboard-central-services.json" + url: "https://raw.githubusercontent.com/mojaloop/helm/${grafana_dashboard_tag}/monitoring/dashboards/mojaloop/dashboard-central-services.json" --- apiVersion: grafana.integreatly.org/v1beta1 kind: GrafanaDashboard @@ -81,7 +81,7 @@ spec: datasources: - inputName: "DS_PROMETHEUS" datasourceName: "Prometheus" - url: "https://raw.githubusercontent.com/mojaloop/helm/v${grafana_dashboard_tag}/monitoring/dashboards/mojaloop/dashboard-ml-adapter.json" + url: "https://raw.githubusercontent.com/mojaloop/helm/${grafana_dashboard_tag}/monitoring/dashboards/mojaloop/dashboard-ml-adapter.json" --- apiVersion: grafana.integreatly.org/v1beta1 kind: GrafanaDashboard @@ -96,7 +96,7 @@ spec: datasources: - inputName: "DS_PROMETHEUS" datasourceName: "Prometheus" - url: "https://raw.githubusercontent.com/mojaloop/helm/v${grafana_dashboard_tag}/monitoring/dashboards/mojaloop/dashboard-simulators.json" + url: "https://raw.githubusercontent.com/mojaloop/helm/${grafana_dashboard_tag}/monitoring/dashboards/mojaloop/dashboard-simulators.json" --- apiVersion: grafana.integreatly.org/v1beta1 kind: GrafanaDashboard @@ -111,7 +111,7 @@ spec: datasources: - inputName: "DS_PROMETHEUS" datasourceName: "Prometheus" - url: "https://raw.githubusercontent.com/mojaloop/helm/v${grafana_dashboard_tag}/monitoring/dashboards/mojaloop/dashboard-quoting-service.json" + url: "https://raw.githubusercontent.com/mojaloop/helm/${grafana_dashboard_tag}/monitoring/dashboards/mojaloop/dashboard-quoting-service.json" --- apiVersion: grafana.integreatly.org/v1beta1 kind: GrafanaDashboard @@ -126,5 +126,5 @@ spec: datasources: - inputName: "DS_PROMETHEUS" datasourceName: "Prometheus" - url: "https://raw.githubusercontent.com/mojaloop/helm/v${grafana_dashboard_tag}/monitoring/dashboards/mojaloop/dashboard-performance-troubleshooting.json" + url: "https://raw.githubusercontent.com/mojaloop/helm/${grafana_dashboard_tag}/monitoring/dashboards/mojaloop/dashboard-performance-troubleshooting.json" --- diff --git a/terraform/gitops/generate-files/templates/monitoring/post-config/dashboards/default.yaml.tpl b/terraform/gitops/generate-files/templates/monitoring/post-config/dashboards/default.yaml.tpl index 6d98f7205..e485bca78 100644 --- a/terraform/gitops/generate-files/templates/monitoring/post-config/dashboards/default.yaml.tpl +++ b/terraform/gitops/generate-files/templates/monitoring/post-config/dashboards/default.yaml.tpl @@ -10,7 +10,7 @@ spec: instanceSelector: matchLabels: dashboards: "grafana" - url: "https://raw.githubusercontent.com/mojaloop/helm/v${grafana_dashboard_tag}/monitoring/dashboards/datastore/dashboard-mysql-exporter-quickstart.json" + url: "https://raw.githubusercontent.com/mojaloop/helm/${grafana_dashboard_tag}/monitoring/dashboards/datastore/dashboard-mysql-exporter-quickstart.json" --- apiVersion: grafana.integreatly.org/v1beta1 kind: GrafanaDashboard @@ -37,7 +37,7 @@ spec: instanceSelector: matchLabels: dashboards: "grafana" - url: "https://raw.githubusercontent.com/mojaloop/helm/v${grafana_dashboard_tag}/monitoring/dashboards/datastore/dashboard-redis-exporter-quickstart.json" + url: "https://raw.githubusercontent.com/mojaloop/helm/${grafana_dashboard_tag}/monitoring/dashboards/datastore/dashboard-redis-exporter-quickstart.json" --- apiVersion: grafana.integreatly.org/v1beta1 kind: GrafanaDashboard @@ -51,7 +51,7 @@ spec: instanceSelector: matchLabels: dashboards: "grafana" - url: "https://raw.githubusercontent.com/mojaloop/helm/v${grafana_dashboard_tag}/monitoring/dashboards/messaging/dashboard-kafka-topic-overview.json" + url: "https://raw.githubusercontent.com/mojaloop/helm/${grafana_dashboard_tag}/monitoring/dashboards/messaging/dashboard-kafka-topic-overview.json" --- apiVersion: grafana.integreatly.org/v1beta1 kind: GrafanaDashboard @@ -65,7 +65,7 @@ spec: instanceSelector: matchLabels: dashboards: "grafana" - url: "https://raw.githubusercontent.com/mojaloop/helm/v${grafana_dashboard_tag}/monitoring/dashboards/messaging/dashboard-kafka-cluster-overview.json" + url: "https://raw.githubusercontent.com/mojaloop/helm/${grafana_dashboard_tag}/monitoring/dashboards/messaging/dashboard-kafka-cluster-overview.json" --- apiVersion: grafana.integreatly.org/v1beta1 diff --git a/terraform/gitops/generate-files/templates/monitoring/post-config/dashboards/k8s.yaml.tpl b/terraform/gitops/generate-files/templates/monitoring/post-config/dashboards/k8s.yaml.tpl index 6271e5da7..ca7df9513 100644 --- a/terraform/gitops/generate-files/templates/monitoring/post-config/dashboards/k8s.yaml.tpl +++ b/terraform/gitops/generate-files/templates/monitoring/post-config/dashboards/k8s.yaml.tpl @@ -19,23 +19,7 @@ spec: instanceSelector: matchLabels: dashboards: "grafana" - url: "https://raw.githubusercontent.com/mojaloop/helm/v16.0.0-snapshot.6/monitoring/dashboards/kubernetes/kubernetes-monitoring-dashboard.json" ---- -apiVersion: grafana.integreatly.org/v1beta1 -kind: GrafanaDashboard -metadata: - name: k8s-addons-prometheus -spec: - folder: kubernetes - instanceSelector: - matchLabels: - dashboards: "grafana" - datasources: - - inputName: "DS_PROMETHEUS" - datasourceName: "Prometheus" - grafanaCom: - id: 19105 - revision: 3 + url: "https://raw.githubusercontent.com/mojaloop/helm/${grafana_dashboard_tag}/monitoring/dashboards/kubernetes/kubernetes-monitoring-dashboard.json" --- apiVersion: grafana.integreatly.org/v1beta1 kind: GrafanaDashboard diff --git a/terraform/gitops/generate-files/templates/monitoring/post-config/dashboards/prometheus.yaml.tpl b/terraform/gitops/generate-files/templates/monitoring/post-config/dashboards/prometheus.yaml.tpl new file mode 100644 index 000000000..f29b32ccf --- /dev/null +++ b/terraform/gitops/generate-files/templates/monitoring/post-config/dashboards/prometheus.yaml.tpl @@ -0,0 +1,44 @@ +apiVersion: grafana.integreatly.org/v1beta1 +kind: GrafanaDashboard +metadata: + name: k8s-addons-prometheus +spec: + folder: monitoring + instanceSelector: + matchLabels: + dashboards: "grafana" + datasources: + - inputName: "DS_PROMETHEUS" + datasourceName: "Prometheus" + grafanaCom: + id: 19105 + revision: 3 +--- +apiVersion: grafana.integreatly.org/v1beta1 +kind: GrafanaDashboard +metadata: + name: prometheus-overview +spec: + folder: monitoring + datasources: + - inputName: "DS_PROMETHEUS" + datasourceName: "Prometheus" + instanceSelector: + matchLabels: + dashboards: "grafana" + url: "https://raw.githubusercontent.com/monitoring-mixins/website/master/assets/prometheus/dashboards/prometheus.json" +--- +apiVersion: grafana.integreatly.org/v1beta1 +kind: GrafanaDashboard +metadata: + name: mojaloop-prometheus-remote-write +spec: + folder: monitoring + datasources: + - inputName: "DS_PROMETHEUS" + datasourceName: "Prometheus" + instanceSelector: + matchLabels: + dashboards: "grafana" + url: "https://raw.githubusercontent.com/mojaloop/helm/${grafana_dashboard_tag}/monitoring/dashboards/infrastructure/prometheus-remote-write.json" +--- \ No newline at end of file diff --git a/terraform/gitops/k8s-cluster-config/monitoring.tf b/terraform/gitops/k8s-cluster-config/monitoring.tf index f22106b3c..10fcead66 100644 --- a/terraform/gitops/k8s-cluster-config/monitoring.tf +++ b/terraform/gitops/k8s-cluster-config/monitoring.tf @@ -126,7 +126,7 @@ locals { prometheus_process_exporter_version = "0.4.2" tempo_chart_version = "3.1.0" grafana_version = "10.2.3" - grafana_dashboard_tag = "16.3.0-snapshot.17" # TODO: update once v16.1.x is published + grafana_dashboard_tag = "v16.3.0-snapshot.17" # TODO: update once v16.1.x is published grafana_operator_version = "3.5.11" monitoring_template_path = "${path.module}/../generate-files/templates/monitoring" monitoring_app_file = "monitoring-app.yaml" diff --git a/terraform/gitops/mojaloop/mojaloop.tf b/terraform/gitops/mojaloop/mojaloop.tf index 36e156f9e..1a94c6850 100644 --- a/terraform/gitops/mojaloop/mojaloop.tf +++ b/terraform/gitops/mojaloop/mojaloop.tf @@ -46,57 +46,57 @@ module "generate_mojaloop_files" { ttk_backend_fqdn = local.ttk_backend_fqdn ttk_istio_gateway_namespace = local.ttk_istio_gateway_namespace ttk_istio_wildcard_gateway_name = local.ttk_istio_wildcard_gateway_name - kafka_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.mojaloop_kafka_resource_index].logical_service_config.logical_service_name,"")}.${var.stateful_resources_namespace}.svc.cluster.local" - kafka_port = try(module.mojaloop_stateful_resources.stateful_resources[local.mojaloop_kafka_resource_index].logical_service_config.logical_service_port,"") - account_lookup_db_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_als_resource_index].logical_service_config.user_password_secret,"") - account_lookup_db_user = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_als_resource_index].logical_service_config.db_username,"") - account_lookup_db_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.ml_als_resource_index].logical_service_config.logical_service_name,"")}.${var.stateful_resources_namespace}.svc.cluster.local" - account_lookup_db_port = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_als_resource_index].logical_service_config.logical_service_port,"") - account_lookup_db_database = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_als_resource_index].logical_service_config.database_name,"") - central_ledger_db_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.user_password_secret,"") - central_ledger_db_user = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.db_username,"") - central_ledger_db_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.logical_service_name,"")}.${var.stateful_resources_namespace}.svc.cluster.local" - central_ledger_db_port = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.logical_service_port,"") - central_ledger_db_database = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.database_name,"") - central_settlement_db_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.user_password_secret,"") - central_settlement_db_user = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.db_username,"") - central_settlement_db_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.logical_service_name,"")}.${var.stateful_resources_namespace}.svc.cluster.local" - central_settlement_db_port = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.logical_service_port,"") - central_settlement_db_database = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.database_name,"") - quoting_db_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.user_password_secret,"") - quoting_db_user = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.db_username,"") - quoting_db_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.logical_service_name,"")}.${var.stateful_resources_namespace}.svc.cluster.local" - quoting_db_port = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.logical_service_port,"") - quoting_db_database = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.database_name,"") - cep_mongodb_database = try(module.mojaloop_stateful_resources.stateful_resources[local.cep_mongodb_resource_index].logical_service_config.database_name,"") - cep_mongodb_user = try(module.mojaloop_stateful_resources.stateful_resources[local.cep_mongodb_resource_index].logical_service_config.db_username,"") - cep_mongodb_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.cep_mongodb_resource_index].logical_service_config.logical_service_name,"")}.${var.stateful_resources_namespace}.svc.cluster.local" - cep_mongodb_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.cep_mongodb_resource_index].logical_service_config.user_password_secret,"") - cep_mongodb_port = try(module.mojaloop_stateful_resources.stateful_resources[local.cep_mongodb_resource_index].logical_service_config.logical_service_port,"") - cl_mongodb_database = try(module.mojaloop_stateful_resources.stateful_resources[local.bulk_mongodb_resource_index].logical_service_config.database_name,"") - cl_mongodb_user = try(module.mojaloop_stateful_resources.stateful_resources[local.bulk_mongodb_resource_index].logical_service_config.db_username,"") - cl_mongodb_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.bulk_mongodb_resource_index].logical_service_config.logical_service_name,"")}.${var.stateful_resources_namespace}.svc.cluster.local" - cl_mongodb_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.bulk_mongodb_resource_index].logical_service_config.user_password_secret,"") - cl_mongodb_port = try(module.mojaloop_stateful_resources.stateful_resources[local.bulk_mongodb_resource_index].logical_service_config.logical_service_port,"") - ttk_mongodb_database = try(module.mojaloop_stateful_resources.stateful_resources[local.ttk_mongodb_resource_index].logical_service_config.database_name,"") - ttk_mongodb_user = try(module.mojaloop_stateful_resources.stateful_resources[local.ttk_mongodb_resource_index].logical_service_config.db_username,"") - ttk_mongodb_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.ttk_mongodb_resource_index].logical_service_config.logical_service_name,"")}.${var.stateful_resources_namespace}.svc.cluster.local" - ttk_mongodb_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.ttk_mongodb_resource_index].logical_service_config.user_password_secret,"") - ttk_mongodb_port = try(module.mojaloop_stateful_resources.stateful_resources[local.ttk_mongodb_resource_index].logical_service_config.logical_service_port,"") - third_party_consent_db_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_consent_oracle_db_resource_index].logical_service_config.user_password_secret,"") - third_party_consent_db_user = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_consent_oracle_db_resource_index].logical_service_config.db_username,"") - third_party_consent_db_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_consent_oracle_db_resource_index].logical_service_config.logical_service_name,"")}.${var.stateful_resources_namespace}.svc.cluster.local" - third_party_consent_db_port = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_consent_oracle_db_resource_index].logical_service_config.logical_service_port,"") - third_party_consent_db_database = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_consent_oracle_db_resource_index].logical_service_config.database_name,"") - third_party_auth_db_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_auth_db_resource_index].logical_service_config.user_password_secret,"") - third_party_auth_db_user = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_auth_db_resource_index].logical_service_config.db_username,"") - third_party_auth_db_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_auth_db_resource_index].logical_service_config.logical_service_name,"")}.${var.stateful_resources_namespace}.svc.cluster.local" - third_party_auth_db_port = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_auth_db_resource_index].logical_service_config.logical_service_port,"") - third_party_auth_db_database = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_auth_db_resource_index].logical_service_config.database_name,"") - third_party_auth_redis_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_redis_resource_index].logical_service_config.logical_service_name,"")}.${var.stateful_resources_namespace}.svc.cluster.local" - third_party_auth_redis_port = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_redis_resource_index].logical_service_config.logical_service_port,"") - ttksims_redis_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.ttk_redis_resource_index].logical_service_config.logical_service_name,"")}.${var.stateful_resources_namespace}.svc.cluster.local" - ttksims_redis_port = try(module.mojaloop_stateful_resources.stateful_resources[local.ttk_redis_resource_index].logical_service_config.logical_service_port,"") + kafka_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.mojaloop_kafka_resource_index].logical_service_config.logical_service_name, "")}.${var.stateful_resources_namespace}.svc.cluster.local" + kafka_port = try(module.mojaloop_stateful_resources.stateful_resources[local.mojaloop_kafka_resource_index].logical_service_config.logical_service_port, "") + account_lookup_db_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_als_resource_index].logical_service_config.user_password_secret, "") + account_lookup_db_user = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_als_resource_index].logical_service_config.db_username, "") + account_lookup_db_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.ml_als_resource_index].logical_service_config.logical_service_name, "")}.${var.stateful_resources_namespace}.svc.cluster.local" + account_lookup_db_port = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_als_resource_index].logical_service_config.logical_service_port, "") + account_lookup_db_database = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_als_resource_index].logical_service_config.database_name, "") + central_ledger_db_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.user_password_secret, "") + central_ledger_db_user = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.db_username, "") + central_ledger_db_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.logical_service_name, "")}.${var.stateful_resources_namespace}.svc.cluster.local" + central_ledger_db_port = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.logical_service_port, "") + central_ledger_db_database = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.database_name, "") + central_settlement_db_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.user_password_secret, "") + central_settlement_db_user = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.db_username, "") + central_settlement_db_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.logical_service_name, "")}.${var.stateful_resources_namespace}.svc.cluster.local" + central_settlement_db_port = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.logical_service_port, "") + central_settlement_db_database = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.database_name, "") + quoting_db_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.user_password_secret, "") + quoting_db_user = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.db_username, "") + quoting_db_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.logical_service_name, "")}.${var.stateful_resources_namespace}.svc.cluster.local" + quoting_db_port = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.logical_service_port, "") + quoting_db_database = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.database_name, "") + cep_mongodb_database = try(module.mojaloop_stateful_resources.stateful_resources[local.cep_mongodb_resource_index].logical_service_config.database_name, "") + cep_mongodb_user = try(module.mojaloop_stateful_resources.stateful_resources[local.cep_mongodb_resource_index].logical_service_config.db_username, "") + cep_mongodb_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.cep_mongodb_resource_index].logical_service_config.logical_service_name, "")}.${var.stateful_resources_namespace}.svc.cluster.local" + cep_mongodb_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.cep_mongodb_resource_index].logical_service_config.user_password_secret, "") + cep_mongodb_port = try(module.mojaloop_stateful_resources.stateful_resources[local.cep_mongodb_resource_index].logical_service_config.logical_service_port, "") + cl_mongodb_database = try(module.mojaloop_stateful_resources.stateful_resources[local.bulk_mongodb_resource_index].logical_service_config.database_name, "") + cl_mongodb_user = try(module.mojaloop_stateful_resources.stateful_resources[local.bulk_mongodb_resource_index].logical_service_config.db_username, "") + cl_mongodb_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.bulk_mongodb_resource_index].logical_service_config.logical_service_name, "")}.${var.stateful_resources_namespace}.svc.cluster.local" + cl_mongodb_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.bulk_mongodb_resource_index].logical_service_config.user_password_secret, "") + cl_mongodb_port = try(module.mojaloop_stateful_resources.stateful_resources[local.bulk_mongodb_resource_index].logical_service_config.logical_service_port, "") + ttk_mongodb_database = try(module.mojaloop_stateful_resources.stateful_resources[local.ttk_mongodb_resource_index].logical_service_config.database_name, "") + ttk_mongodb_user = try(module.mojaloop_stateful_resources.stateful_resources[local.ttk_mongodb_resource_index].logical_service_config.db_username, "") + ttk_mongodb_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.ttk_mongodb_resource_index].logical_service_config.logical_service_name, "")}.${var.stateful_resources_namespace}.svc.cluster.local" + ttk_mongodb_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.ttk_mongodb_resource_index].logical_service_config.user_password_secret, "") + ttk_mongodb_port = try(module.mojaloop_stateful_resources.stateful_resources[local.ttk_mongodb_resource_index].logical_service_config.logical_service_port, "") + third_party_consent_db_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_consent_oracle_db_resource_index].logical_service_config.user_password_secret, "") + third_party_consent_db_user = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_consent_oracle_db_resource_index].logical_service_config.db_username, "") + third_party_consent_db_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_consent_oracle_db_resource_index].logical_service_config.logical_service_name, "")}.${var.stateful_resources_namespace}.svc.cluster.local" + third_party_consent_db_port = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_consent_oracle_db_resource_index].logical_service_config.logical_service_port, "") + third_party_consent_db_database = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_consent_oracle_db_resource_index].logical_service_config.database_name, "") + third_party_auth_db_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_auth_db_resource_index].logical_service_config.user_password_secret, "") + third_party_auth_db_user = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_auth_db_resource_index].logical_service_config.db_username, "") + third_party_auth_db_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_auth_db_resource_index].logical_service_config.logical_service_name, "")}.${var.stateful_resources_namespace}.svc.cluster.local" + third_party_auth_db_port = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_auth_db_resource_index].logical_service_config.logical_service_port, "") + third_party_auth_db_database = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_auth_db_resource_index].logical_service_config.database_name, "") + third_party_auth_redis_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_redis_resource_index].logical_service_config.logical_service_name, "")}.${var.stateful_resources_namespace}.svc.cluster.local" + third_party_auth_redis_port = try(module.mojaloop_stateful_resources.stateful_resources[local.third_party_redis_resource_index].logical_service_config.logical_service_port, "") + ttksims_redis_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.ttk_redis_resource_index].logical_service_config.logical_service_name, "")}.${var.stateful_resources_namespace}.svc.cluster.local" + ttksims_redis_port = try(module.mojaloop_stateful_resources.stateful_resources[local.ttk_redis_resource_index].logical_service_config.logical_service_port, "") account_lookup_service_replica_count = try(var.app_var_map.account_lookup_service_replica_count, 1) account_lookup_service_admin_replica_count = try(var.app_var_map.account_lookup_service_admin_replica_count, 1) quoting_service_replica_count = try(var.app_var_map.quoting_service_replica_count, 1) @@ -147,7 +147,7 @@ module "generate_mojaloop_files" { quoting_service_monitoring_prefix = try(var.app_var_map.quoting_service_monitoring_prefix, "moja_qs_") ml_api_adapter_monitoring_prefix = try(var.app_var_map.ml_api_adapter_monitoring_prefix, "moja_ml_") account_lookup_service_monitoring_prefix = try(var.app_var_map.account_lookup_service_monitoring_prefix, "moja_als_") - grafana_dashboard_tag = try(var.app_var_map.grafana_dashboard_tag, var.mojaloop_chart_version) + grafana_dashboard_tag = try(var.app_var_map.grafana_dashboard_tag, "v${var.mojaloop_chart_version}") bof_release_name = var.bof_release_name ory_namespace = var.ory_namespace bof_role_perm_operator_host = "${var.bof_release_name}-security-role-perm-operator-svc.${var.ory_namespace}.svc.cluster.local" @@ -155,17 +155,17 @@ module "generate_mojaloop_files" { central_admin_host = "${var.mojaloop_release_name}-centralledger-service" central_settlements_host = "${var.mojaloop_release_name}-centralsettlement-service" account_lookup_service_host = "${var.mojaloop_release_name}-account-lookup-service" - reporting_db_secret_name = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.user_password_secret,"") - reporting_db_user = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.db_username,"") - reporting_db_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.logical_service_name,"")}.${var.stateful_resources_namespace}.svc.cluster.local" - reporting_db_port = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.logical_service_port,"") - reporting_db_database = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.database_name,"") + reporting_db_secret_name = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.user_password_secret, "") + reporting_db_user = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.db_username, "") + reporting_db_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.logical_service_name, "")}.${var.stateful_resources_namespace}.svc.cluster.local" + reporting_db_port = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.logical_service_port, "") + reporting_db_database = try(module.mojaloop_stateful_resources.stateful_resources[local.ml_cl_resource_index].logical_service_config.database_name, "") reporting_db_secret_key = "mysql-password" - reporting_events_mongodb_database = try(module.mojaloop_stateful_resources.stateful_resources[local.reporting_events_mongodb_resource_index].logical_service_config.database_name,"") - reporting_events_mongodb_user = try(module.mojaloop_stateful_resources.stateful_resources[local.reporting_events_mongodb_resource_index].logical_service_config.db_username,"") - reporting_events_mongodb_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.reporting_events_mongodb_resource_index].logical_service_config.logical_service_name,"")}.${var.stateful_resources_namespace}.svc.cluster.local" - reporting_events_mongodb_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.reporting_events_mongodb_resource_index].logical_service_config.user_password_secret,"") - reporting_events_mongodb_port = try(module.mojaloop_stateful_resources.stateful_resources[local.reporting_events_mongodb_resource_index].logical_service_config.logical_service_port,"") + reporting_events_mongodb_database = try(module.mojaloop_stateful_resources.stateful_resources[local.reporting_events_mongodb_resource_index].logical_service_config.database_name, "") + reporting_events_mongodb_user = try(module.mojaloop_stateful_resources.stateful_resources[local.reporting_events_mongodb_resource_index].logical_service_config.db_username, "") + reporting_events_mongodb_host = "${try(module.mojaloop_stateful_resources.stateful_resources[local.reporting_events_mongodb_resource_index].logical_service_config.logical_service_name, "")}.${var.stateful_resources_namespace}.svc.cluster.local" + reporting_events_mongodb_existing_secret = try(module.mojaloop_stateful_resources.stateful_resources[local.reporting_events_mongodb_resource_index].logical_service_config.user_password_secret, "") + reporting_events_mongodb_port = try(module.mojaloop_stateful_resources.stateful_resources[local.reporting_events_mongodb_resource_index].logical_service_config.logical_service_port, "") keto_read_url = "http://keto-read.${var.ory_namespace}.svc.cluster.local:80" keto_write_url = "http://keto-write.${var.ory_namespace}.svc.cluster.local:80" kratos_service_name = "kratos-public.${var.ory_namespace}.svc.cluster.local" diff --git a/terraform/gitops/stateful-resources/stateful-resources-config.tf b/terraform/gitops/stateful-resources/stateful-resources-config.tf index fcd2f580c..b57607499 100644 --- a/terraform/gitops/stateful-resources/stateful-resources-config.tf +++ b/terraform/gitops/stateful-resources/stateful-resources-config.tf @@ -61,7 +61,9 @@ resource "local_file" "strimzi-crs" { for_each = { for key, stateful_resource in local.strimzi_operator_stateful_resources : key => stateful_resource } content = templatefile("${local.stateful_resources_template_path}/strimzi/kafka/kafka-with-dual-role-nodes.yaml.tpl", { - kafka_cluster_name = each.key + kafka_cluster_name = each.key + kafka_cluster_metrics_label = var.cluster_name + node_pool_name = "${each.key}-nodepool" node_pool_size = each.value.local_operator_config.node_pool_size node_pool_storage_size = each.value.local_operator_config.kafka_data.storage_size diff --git a/terraform/gitops/stateful-resources/templates/stateful-resources/strimzi/kafka/kafka-with-dual-role-nodes.yaml.tpl b/terraform/gitops/stateful-resources/templates/stateful-resources/strimzi/kafka/kafka-with-dual-role-nodes.yaml.tpl index 8e2385391..40faf56c0 100644 --- a/terraform/gitops/stateful-resources/templates/stateful-resources/strimzi/kafka/kafka-with-dual-role-nodes.yaml.tpl +++ b/terraform/gitops/stateful-resources/templates/stateful-resources/strimzi/kafka/kafka-with-dual-role-nodes.yaml.tpl @@ -297,6 +297,12 @@ spec: targetLabel: node_ip replacement: $1 action: replace + - source_labels: [] + targetLabel: 'strimzi_io_cluster' + replacement: ${kafka_cluster_metrics_label} + action: replace + + --- apiVersion: grafana.integreatly.org/v1beta1 kind: GrafanaFolder diff --git a/terraform/k8s/default-config/common-vars.yaml b/terraform/k8s/default-config/common-vars.yaml index de50c342f..7dceb63c0 100644 --- a/terraform/k8s/default-config/common-vars.yaml +++ b/terraform/k8s/default-config/common-vars.yaml @@ -24,7 +24,7 @@ prometheus_operator_version: 8.22.8 prometheus_process_exporter_version: 0.4.2 grafana_operator_version: 3.5.11 grafana_version: 10.2.3 -grafana_dashboard_tag: "16.3.0-snapshot.17" # TODO: update once v16.1.x is published +grafana_dashboard_tag: v16.3.0-snapshot.21 # TODO: update once v16.1.x is published tempo_chart_version: 3.1.0 loki_chart_version: 2.13.0 loki_ingester_pvc_size: 10Gi diff --git a/terraform/k8s/default-config/mojaloop-vars.yaml b/terraform/k8s/default-config/mojaloop-vars.yaml index cfb687fac..1f22df411 100644 --- a/terraform/k8s/default-config/mojaloop-vars.yaml +++ b/terraform/k8s/default-config/mojaloop-vars.yaml @@ -7,7 +7,7 @@ mcm_ingress_internal_lb: false mojaloop_ingress_internal_lb: true finance_portal_ingress_internal_lb: true onboarding_collection_tag: 15.2.0 -grafana_dashboard_tag: 16.3.0-snapshot.17 # TODO: update once v16.1.x is published +grafana_dashboard_tag: v16.3.0-snapshot.21 # TODO: update once v16.1.x is published enable_istio_injection: true central_ledger_handler_transfer_position_batch_processing_enabled: false central_ledger_handler_transfer_position_batch_size: 100