<commit_before>resource "postgresql_database" "rating" {
  name  = "rating"
  owner = postgresql_role.rating.name
}

resource "random_password" "pgsql_rating_user_password" {
  length = 24
}

resource "postgresql_role" "rating" {
  name     = "rating"
  login    = true
  password = <PASSWORD>
}

# This (sensitive) output is meant to be encrypted into the production secret system, to be provided as a secret to the ratings.jenkins.io application
output "rating_dbconfig" {
  sensitive   = true
  description = "file /config/dbconfig.php"
  value       = <<-EOT
    <?php
      $dbuser='${local.public_pgsql_admin_login}';
      $dbpass='${<PASSWORD>}';
      $dbname='rating';
      $dbserver='${azurerm_postgresql_flexible_server.public.fqdn}';
      $dbport='';
  EOT
}<commit_msg>fix(rating): reformat secrets output for sops (#186)<commit_after>resource "postgresql_database" "rating" {
  name  = "rating"
  owner = postgresql_role.rating.name
}

resource "random_password" "pgsql_rating_user_password" {
  length = 24
}

resource "postgresql_role" "rating" {
  name     = "rating"
  login    = true
  password = <PASSWORD>
}

# This (sensitive) output is meant to be encrypted into the production secret system, to be provided as a secret to the ratings.jenkins.io application
output "rating_dbconfig" {
  sensitive   = true
  description = "YAML helm (secret) values for the helm-chart jenkins-infra/rating"
  value       = <<-EOT
database:
  username: "${local.public_pgsql_admin_login}"
  password: <PASSWORD>}"
  server: "${azurerm_postgresql_flexible_server.public.fqdn}"
  name: "${postgresql_database.rating.name}"
  EOT
}
{'fraction_non_alphanumeric': 0.11613691931540342, 'fraction_numerical': 0.004278728606356968, 'mean_word_length': 4.213375796178344, 'pattern_counts': {'":': 0, '<': 12, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2601237', 'n_tokens_mistral': 559, 'n_tokens_neox': 539, 'n_words': 135}