docs icon indicating copy to clipboard operation
docs copied to clipboard

Add Terraform Cloud/Enterprise exporter.

Open iorubs opened this issue 4 years ago • 2 comments

Hi @RichiH,

Could you please review this exporter and see if it meets the requirements?

Thanks.

iorubs avatar Feb 05 '21 17:02 iorubs

@iorubs Can you provide a sample of the output?

hdost avatar Jun 27 '22 10:06 hdost

@iorubs Can you provide a sample of the output?

@hdost here's the sample output:

# HELP tf_exporter_collector_duration_seconds Collector time duration.
# TYPE tf_exporter_collector_duration_seconds gauge
tf_exporter_collector_duration_seconds{collector="collect.organizations"} 0.939581875
tf_exporter_collector_duration_seconds{collector="collect.workspaces"} 0.76836625
# HELP tf_exporter_last_scrape_error Whether the last scrape of metrics from Terraform API resulted in an error (1 for error, 0 for success).
# TYPE tf_exporter_last_scrape_error gauge
tf_exporter_last_scrape_error 0
# HELP tf_exporter_scrapes_total Total number of times the Terraform API was scraped for metrics.
# TYPE tf_exporter_scrapes_total counter
tf_exporter_scrapes_total 3
# HELP tf_organizations_info Information about existing organizations
# TYPE tf_organizations_info gauge
tf_organizations_info{created_at="2020-12-18 00:15:39.768 +0000 UTC",email="[email protected]",external_id="org-MkXS4Ct7RgeU2fjb",name="iorubs",owners_team_saml_role_id="",saml_enabled="false",two_factor_conformant="false"} 1
tf_organizations_info{created_at="2021-02-06 17:31:17.278 +0000 UTC",email="[email protected]",external_id="org-JDsFua64naveuyoH",name="iorubs-dev",owners_team_saml_role_id="",saml_enabled="false",two_factor_conformant="false"} 1
# HELP tf_workspaces_info Information about existing workspaces
# TYPE tf_workspaces_info gauge
tf_workspaces_info{created_at="2020-12-18 00:17:06.348 +0000 UTC",current_run="run-ABNAoY2UnU1TTtYk",current_run_created_at="2021-01-19 15:23:37.118 +0000 UTC",current_run_status="applied",environment="default",id="ws-r5YTHZyVUdaJFR4w",name="dev",organization="iorubs",terraform_version="0.14.3"} 1
tf_workspaces_info{created_at="2021-02-06 22:41:21.416 +0000 UTC",current_run="run-r73P6CGE8iatHBXY",current_run_created_at="2021-02-16 17:44:42.021 +0000 UTC",current_run_status="errored",environment="default",id="ws-6e7eHxjoLR5LZPpu",name="stg",organization="iorubs",terraform_version="0.14.6"} 1
tf_workspaces_info{created_at="2021-02-16 16:35:47.662 +0000 UTC",current_run="run-vSntsgUSpEWgm1oW",current_run_created_at="2021-02-16 17:49:08.326 +0000 UTC",current_run_status="applied",environment="default",id="ws-FX2W9pVxYypR3G8i",name="dev",organization="iorubs-dev",terraform_version="0.14.6"} 1
tf_workspaces_info{created_at="2021-02-16 17:30:23.202 +0000 UTC",current_run="na",current_run_created_at="na",current_run_status="na",environment="default",id="ws-d1rZgzz5zqVSDFm6",name="prod",organization="iorubs",terraform_version="0.14.6"} 1
tf_workspaces_info{created_at="2021-02-16 17:49:34.62 +0000 UTC",current_run="run-6KWmJLnhBrsbTQNa",current_run_created_at="2021-02-16 17:50:38.12 +0000 UTC",current_run_status="planned_and_finished",environment="default",id="ws-N2addebChqWaXj5p",name="prod",organization="iorubs-dev",terraform_version="0.14.6"} 1

Thanks.

iorubs avatar Jun 29 '22 23:06 iorubs