prometheus-to-monitoring

AckeeCZ/prometheus-to-monitoring/gcp

Terraform Module HCL GCP

Cloud Functions based translate of prometheus monitoring metrics to Google Cloud Monitoring

Install
module "prometheus-to-monitoring" {
source = "AckeeCZ/prometheus-to-monitoring/gcp"
version = "1.0.0"
}
plain text: /constructs/tfmod-ackeecz-prometheus-to-monitoring-gcp/install.txt
⭐ Source on GitHub 📦 Registry page
README

Terraform module for pushing Prometheus metrics to Google Cloud Monitoring Module is based on Cloud Function called by Cloud Scheduler. Each call says which endpoint should be pushed to Google Cloud Monitoring custom metrics. For further setup, use variable scrape_jobs, e.g.: ``hcl module "metrics_push" { source = "../" # use correct module path project_id = var.project scrape_jobs = { testing : { schedule : " " endpoint : "https://example.com/metrics" } } region = var.region } ` Each key in scrape_jobs can contain following keys: schedule (required) - cronline endpoint (required) - url to metrics endpoint description - used for scheduler description time_zone - time zone, default "Europe/Prague" Kuddos for https://github.com/google/go-metrics-stackdriver/blob/main/stackdriver.go on how to

Inputs (3)
NameTypeDescriptionDefault
regionstringGCP region required
project_idstringProject ID required
scrape_jobsmap(map(string))Metrics scraping setup, each item needs key schedule (e.g. * * * * *) and endpoi required
Outputs (1)
sa — Service account used for Cloud Function runtime email
Resources (8)
google_cloud_scheduler_jobgoogle_cloudfunctions_functiongoogle_cloudfunctions_function_iam_membergoogle_project_iam_membergoogle_service_accountgoogle_storage_bucketgoogle_storage_bucket_objectrandom_string
Details
FrameworkTerraform Module
LanguageHCL
Version1.0.0
Cloud GCP
★ Stars0
Forks0
Total downloads3.5k
Inputs3
Outputs1
Resources8
NamespaceAckeeCZ
Updated