Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
githubjianli authored Jan 5, 2024
1 parent 4b143f2 commit df7344b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions common.tf
Original file line number Diff line number Diff line change
Expand Up @@ -51,17 +51,17 @@ data "aws_iam_policy_document" "waggle_dance_glue_policy" {


data "aws_secretsmanager_secret" "datadog_key" {
count = length(data.aws_secretsmanager_secret.datadog_key) > 0 ? 1 : 0
count = length(var.datadog_key_secret_name) > 0 ? 1 : 0
name = var.datadog_key_secret_name
}

data "aws_secretsmanager_secret_version" "datadog_key" {
count = length(data.aws_secretsmanager_secret.datadog_key) > 0 ? 1 : 0
count = length(var.datadog_key_secret_name) > 0 ? 1 : 0
secret_id = data.aws_secretsmanager_secret.datadog_key[0].id
}

locals {
datadog_keys = length(data.aws_secretsmanager_secret.datadog_key) > 0 ? {} : jsondecode(data.aws_secretsmanager_secret_version.datadog_key[0].secret_string)
datadog_keys = length(var.var.datadog_key_secret_name) > 0 ? {} : jsondecode(data.aws_secretsmanager_secret_version.datadog_key[0].secret_string)
}

provider "datadog" {
Expand Down

0 comments on commit df7344b

Please sign in to comment.