Setup for Prometheus + Variant on Cloudfoundry.
- Deploys a Prometheus instance set up for Remote Write
- Variant sidecar for scrape target and rule discovery
module "variant" {
source = "philips-labs/variant/cloudfoundry"
version = "6.0.1"
remote_write_config = file("remote_write.yaml")
cf_org_name = var.cf_org_name
cf_space_id = var.cf_space_id
cf_functional_account = {
api_endpoint = var.cf_api_url
username = var.cf_username
password = var.cf_password
}
}
Name | Version |
---|---|
terraform | >= 1.0.0 |
cloudfoundry | >= 0.50.4 |
hsdp | >= 0.30.10 |
random | >= 2.2.1 |
Name | Version |
---|---|
cloudfoundry | >= 0.50.4 |
hsdp | >= 0.30.10 |
random | >= 2.2.1 |
No modules.
Name | Type |
---|---|
cloudfoundry_app.prometheus | resource |
cloudfoundry_network_policy.prometheus | resource |
cloudfoundry_route.prometheus | resource |
cloudfoundry_route.prometheus_internal | resource |
random_id.id | resource |
random_password.password | resource |
cloudfoundry_domain.app_domain | data source |
cloudfoundry_domain.apps_internal_domain | data source |
cloudfoundry_org.org | data source |
hsdp_config.cf | data source |
Name | Description | Type | Default | Required |
---|---|---|---|---|
alertmanagers_endpoints | List of endpoints of the alert managers | list(string) |
[] |
no |
cf_functional_account | Configuration for the CloudFoundry functional account. Required for variant. | object({ |
n/a | yes |
cf_org_name | Cloudfoundry ORG name to use for reverse proxy | string |
n/a | yes |
cf_space_id | Cloudfoundry SPACE id to use for deploying all Thanos components. | string |
n/a | yes |
docker_password | Docker registry password | string |
"" |
no |
docker_username | Docker registry username | string |
"" |
no |
environment | Pass environment variable to the app | map(any) |
{} |
no |
external_labels | External labels to add | map(any) |
{ |
no |
mtls_cert | Base64 encoded certificate for prometheus mtls communication | string |
"" |
no |
mtls_private_key | Base64 encoded private key for prometheus mtls communication | string |
"" |
no |
name_postfix | The postfix string to append to the space, hostname, etc. Prevents namespace clashes | string |
"" |
no |
network_policies | The container-to-container network policies to create with Prometheus as the source app | list(object({ |
[] |
no |
prometheus_disk_quota | Prometheus disk quota | number |
5000 |
no |
prometheus_evaluation_interval | prometheus rules evaluation interval | string |
"15s" |
no |
prometheus_memory | Prometheus memory | number |
1024 |
no |
prometheus_public_endpoints | prometheus public endpoint | bool |
false |
no |
prometheus_scrape_interval | prometheus scrape interval | string |
"15s" |
no |
remote_write_config | The Promethues remote write section to inject | string |
"" |
no |
remote_write_url | Remote write endpoint for prometheus tls communication | string |
"" |
no |
spaces | The list of CF space GUIDs to scrape. When provided variant will only consider apps in these spaces | list(string) |
[] |
no |
strategy | Deployment strategy to use | string |
"rolling" |
no |
tenants | The list of tenants to scrape. When an app does not specify tenant then 'default' is used | list(string) |
[ |
no |
variant_image | Image to use for Thanos app. Use a v* tagged version to prevent automatic updates | string |
"philipslabs/cf-variant:v6.3.0" |
no |
Name | Description |
---|---|
postfix | Cluster ID / Postfix of Prometheus deployment |
prometheus_app_id | App id for Promethues |
prometheus_space_id | Cloud foundry space ID of Prometheus |