Skip to content

Commit

Permalink
Merge pull request #349 from aztfmod/fmt
Browse files Browse the repository at this point in the history
Terraform 14 FMT
  • Loading branch information
arnaudlh authored Mar 25, 2021
2 parents fbbf064 + eca4aeb commit e3cbe04
Show file tree
Hide file tree
Showing 522 changed files with 3,327 additions and 3,290 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/master-100-tf13.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ jobs:

steps:
- uses: actions/checkout@v2

- name: Login azure
run: |
az login --service-principal -u '${{ env.ARM_CLIENT_ID }}' -p '${{ env.ARM_CLIENT_SECRET }}' --tenant '${{ env.ARM_TENANT_ID }}'
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/master-standalone-tf14.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ jobs:
"recovery_vault/103-asr-with-private-endpoint",
"redis_cache/100-redis-standard",
"storage_accounts/100-simple-storage-account-blob-container",
"storage_accounts/102-storage-account-advanced-options",
"storage_accounts/102-storage-account-advanced-options",
"synapse_analytics/100-synapse",
"synapse_analytics/101-synapse-sparkpool",
"webapps/appservice/101-appservice-simple",
Expand Down
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ repos:
hooks:
- id: check-merge-conflict
- id: trailing-whitespace
- id: check-yaml
# - id: check-yaml
- id: check-added-large-files
- id: detect-private-key
# - repo: git://github.com/markdownlint/markdownlint
Expand Down
4 changes: 2 additions & 2 deletions aks_clusters.tf
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
output aks_clusters {
output "aks_clusters" {
value = module.aks_clusters
}

module aks_clusters {
module "aks_clusters" {
source = "./modules/compute/aks"
depends_on = [module.networking]
for_each = local.compute.aks_clusters
Expand Down
6 changes: 3 additions & 3 deletions app_config.tf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module app_config {
module "app_config" {
source = "./modules/databases/app_config"
for_each = local.database.app_config
name = each.value.name
Expand All @@ -13,6 +13,6 @@ module app_config {
tags = try(each.value.tags, {})
}

output app_config {
value = module.app_config
output "app_config" {
value = module.app_config
}
2 changes: 1 addition & 1 deletion app_service_plans.tf
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ module "app_service_plans" {
global_settings = local.global_settings
}

output app_service_plans {
output "app_service_plans" {
value = module.app_service_plans

}
10 changes: 5 additions & 5 deletions application_security_groups.tf
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
module application_security_groups {
module "application_security_groups" {
source = "./modules/networking/application_security_group"

for_each = local.networking.application_security_groups

settings = each.value
global_settings = local.global_settings
resource_group_name = module.resource_groups[each.value.resource_group_key].name
base_tags = try(local.global_settings.inherit_tags, false) ? module.resource_groups[each.value.resource_group_key].tags : {}
location = lookup(each.value, "region", null) == null ? module.resource_groups[each.value.resource_group_key].location : local.global_settings.regions[each.value.region]

}

output application_security_groups {
output "application_security_groups" {
value = module.application_security_groups

}
Expand Down
4 changes: 2 additions & 2 deletions automations.tf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

module automations {
module "automations" {
source = "./modules/automation"
for_each = local.shared_services.automations

Expand All @@ -11,7 +11,7 @@ module automations {
base_tags = try(local.global_settings.inherit_tags, false) ? module.resource_groups[each.value.resource_group_key].tags : {}
}

output automations {
output "automations" {
value = module.automations

}
4 changes: 2 additions & 2 deletions availability_sets.tf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module availability_sets {
module "availability_sets" {
source = "./modules/compute/availability_set"
for_each = local.compute.availability_sets

Expand All @@ -17,7 +17,7 @@ module availability_sets {



output availability_sets {
output "availability_sets" {
value = module.availability_sets

}
14 changes: 7 additions & 7 deletions azuread.tf
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
# Azure Active Directory Applications
#

module azuread_applications {
module "azuread_applications" {
source = "./modules/azuread/applications"
depends_on = [module.keyvault_access_policies]
for_each = var.azuread_apps
Expand All @@ -15,7 +15,7 @@ module azuread_applications {
user_type = var.user_type
}

output aad_apps {
output "aad_apps" {
value = module.azuread_applications

}
Expand All @@ -24,7 +24,7 @@ output aad_apps {
# Azure Active Directory Groups
#

module azuread_groups {
module "azuread_groups" {
source = "./modules/azuread/groups"
for_each = var.azuread_groups

Expand All @@ -33,12 +33,12 @@ module azuread_groups {
tenant_id = local.client_config.tenant_id
}

output azuread_groups {
output "azuread_groups" {
value = module.azuread_groups

}

module azuread_groups_members {
module "azuread_groups_members" {
source = "./modules/azuread/groups_members"
for_each = var.azuread_groups

Expand All @@ -52,7 +52,7 @@ module azuread_groups_members {
# Azure Active Directory Users
#

module azuread_users {
module "azuread_users" {
source = "./modules/azuread/users"
depends_on = [module.keyvault_access_policies]
for_each = var.azuread_users
Expand All @@ -63,7 +63,7 @@ module azuread_users {
settings = each.value
}

output azuread_users {
output "azuread_users" {
value = module.azuread_users

}
10 changes: 5 additions & 5 deletions azuread_roles.tf
Original file line number Diff line number Diff line change
@@ -1,37 +1,37 @@

module azuread_roles_applications {
module "azuread_roles_applications" {
source = "./modules/azuread/roles"
for_each = try(var.azuread_roles.azuread_apps, {})

object_id = module.azuread_applications[each.key].azuread_service_principal.object_id
azuread_roles = each.value.roles
}

module azuread_roles_msi {
module "azuread_roles_msi" {
source = "./modules/azuread/roles"
for_each = try(var.azuread_roles.managed_identities, {})

object_id = module.managed_identities[each.key].principal_id
azuread_roles = each.value.roles
}

module azuread_roles_sql_mi {
module "azuread_roles_sql_mi" {
source = "./modules/azuread/roles"
for_each = try(var.azuread_roles.mssql_managed_instances, {})

object_id = module.mssql_managed_instances[each.key].principal_id
azuread_roles = each.value.roles
}

module azuread_roles_sql_mi_secondary {
module "azuread_roles_sql_mi_secondary" {
source = "./modules/azuread/roles"
for_each = try(var.azuread_roles.mssql_managed_instances_secondary, {})

object_id = module.mssql_managed_instances_secondary[each.key].principal_id
azuread_roles = each.value.roles
}

module azuread_roles_mssql_server {
module "azuread_roles_mssql_server" {
source = "./modules/azuread/roles"
for_each = try(var.azuread_roles.mssql_servers, {})

Expand Down
4 changes: 2 additions & 2 deletions azurerm_application_insights.tf
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@ module "azurerm_application_insights" {
base_tags = try(local.global_settings.inherit_tags, false) ? module.resource_groups[each.value.resource_group_key].tags : {}
}

output application_insights {
value = module.azurerm_application_insights
output "application_insights" {
value = module.azurerm_application_insights
}
2 changes: 1 addition & 1 deletion bastion_service.tf
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ resource "azurerm_bastion_host" "host" {
}
}

module bastion_host_diagnostics {
module "bastion_host_diagnostics" {
source = "./modules/diagnostics"
for_each = try(local.compute.bastion_hosts, {})

Expand Down
4 changes: 2 additions & 2 deletions container_groups.tf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module container_groups {
module "container_groups" {
source = "./modules/compute/container_group"
for_each = local.compute.container_groups

Expand All @@ -20,7 +20,7 @@ module container_groups {
}
}

output container_groups {
output "container_groups" {
value = module.container_groups
}

4 changes: 2 additions & 2 deletions container_registry.tf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module container_registry {
module "container_registry" {
source = "./modules/compute/container_registry"
for_each = local.compute.azure_container_registries

Expand All @@ -21,7 +21,7 @@ module container_registry {
private_dns = local.combined_objects_private_dns
}

output azure_container_registries {
output "azure_container_registries" {
value = module.container_registry

}
Expand Down
6 changes: 3 additions & 3 deletions cosmos_db.tf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module cosmos_dbs {
module "cosmos_dbs" {
source = "./modules/databases/cosmos_dbs"
for_each = local.database.cosmos_dbs

Expand All @@ -9,6 +9,6 @@ module cosmos_dbs {
base_tags = try(local.global_settings.inherit_tags, false) ? module.resource_groups[each.value.resource_group_key].tags : {}
}

output cosmos_dbs {
value = module.cosmos_dbs
output "cosmos_dbs" {
value = module.cosmos_dbs
}
4 changes: 2 additions & 2 deletions databricks.tf
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module databricks_workspaces {
module "databricks_workspaces" {
source = "./modules/analytics/databricks_workspace"
for_each = local.database.databricks_workspaces

Expand All @@ -11,7 +11,7 @@ module databricks_workspaces {
base_tags = try(local.global_settings.inherit_tags, false) ? module.resource_groups[each.value.resource_group_key].tags : {}
}

output databricks_workspaces {
output "databricks_workspaces" {
value = module.databricks_workspaces

}
Expand Down
8 changes: 4 additions & 4 deletions diagnostics.tf
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,12 @@ locals {
}

# Output diagnostics
output diagnostics {
output "diagnostics" {
value = local.combined_diagnostics

}

module diagnostic_storage_accounts {
module "diagnostic_storage_accounts" {
source = "./modules/storage_account"
for_each = local.diagnostics.diagnostic_storage_accounts

Expand All @@ -46,7 +46,7 @@ module "diagnostic_event_hub_namespaces" {
base_tags = try(local.global_settings.inherit_tags, false) ? module.resource_groups[each.value.resource_group_key].tags : {}
}

module diagnostic_event_hub_namespaces_diagnostics {
module "diagnostic_event_hub_namespaces_diagnostics" {
source = "./modules/diagnostics"
for_each = local.diagnostics.diagnostic_event_hub_namespaces

Expand All @@ -66,7 +66,7 @@ module "diagnostic_log_analytics" {
base_tags = try(local.global_settings.inherit_tags, false) ? module.resource_groups[each.value.resource_group_key].tags : {}
}

module diagnostic_log_analytics_diagnostics {
module "diagnostic_log_analytics_diagnostics" {
source = "./modules/diagnostics"
for_each = local.diagnostics.diagnostic_log_analytics

Expand Down
2 changes: 1 addition & 1 deletion disk_encryption_sets.tf
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ module "disk_encryption_sets" {
keyvault_id = local.combined_objects_keyvaults[try(each.value.keyvault.lz_key, local.client_config.landingzone_key)][each.value.keyvault.key].id
}

output disk_encryption_sets {
output "disk_encryption_sets" {
value = module.disk_encryption_sets
}
4 changes: 2 additions & 2 deletions dynamic_secrets.tf
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
# For that reason, object must not be set.
# This is only used here for examples to run
# the normal recommendation for dynamic keyvault secrets is to call it from a landingzone
module dynamic_keyvault_secrets {
module "dynamic_keyvault_secrets" {
source = "./modules/security/dynamic_keyvault_secrets"
depends_on = [module.keyvaults]
for_each = try(var.security.dynamic_keyvault_secrets, {})
Expand All @@ -12,6 +12,6 @@ module dynamic_keyvault_secrets {
keyvault = local.combined_objects_keyvaults[local.client_config.landingzone_key][each.key]
}

output dynamic_keyvault_secrets {
output "dynamic_keyvault_secrets" {
value = module.dynamic_keyvault_secrets
}
Loading

0 comments on commit e3cbe04

Please sign in to comment.