format
This commit is contained in:
parent
2ffaa5060e
commit
d5a0c28c11
2 changed files with 9 additions and 9 deletions
|
|
@ -71,7 +71,7 @@ resource "grafana_data_source_config" "loki_derived_fields" {
|
|||
for_each = {
|
||||
for k, v in var.datasources : k => v if v.type == "loki" && v.derived_fields != null
|
||||
}
|
||||
uid = grafana_data_source.this[each.key].uid
|
||||
uid = grafana_data_source.this[each.key].uid
|
||||
json_data_encoded = jsonencode({
|
||||
derivedFields = [
|
||||
for field in each.value.derived_fields : {
|
||||
|
|
@ -94,7 +94,7 @@ resource "grafana_data_source_config" "tempo_traces_to_logs" {
|
|||
for_each = {
|
||||
for k, v in var.datasources : k => v if v.type == "tempo" && v.traces_to_logs != null
|
||||
}
|
||||
uid = grafana_data_source.this[each.key].uid
|
||||
uid = grafana_data_source.this[each.key].uid
|
||||
json_data_encoded = jsonencode({
|
||||
tracesToLogsV2 = {
|
||||
datasourceUid = grafana_data_source.this[each.value.traces_to_logs.target_datasource_name].uid
|
||||
|
|
|
|||
|
|
@ -5,18 +5,18 @@ Each datasource specifies type, keys to lookup URL/user/password,
|
|||
and optional configurations for linking data sources.
|
||||
EOT
|
||||
type = map(object({
|
||||
type = string
|
||||
url_key = string
|
||||
pass_key = optional(string)
|
||||
is_default = optional(bool)
|
||||
type = string
|
||||
url_key = string
|
||||
pass_key = optional(string)
|
||||
is_default = optional(bool)
|
||||
|
||||
# Key to look up a database username
|
||||
db_user_key = optional(string)
|
||||
db_user_key = optional(string)
|
||||
# Key to look up a basic auth username
|
||||
basic_auth_user_key = optional(string)
|
||||
basic_auth_user_key = optional(string)
|
||||
|
||||
# Non-sensitive JSON data for Postgres, etc.
|
||||
json_data = optional(map(any))
|
||||
json_data = optional(map(any))
|
||||
|
||||
# Linking Attributes (for Loki/Tempo)
|
||||
derived_fields = optional(list(object({
|
||||
|
|
|
|||
Loading…
Reference in a new issue