Skip to content

data-platform-hq/terraform-azurerm-mssql-database

Repository files navigation

Azure Microsoft SQL Database Terraform module

Terraform module for creation Azure Microsoft SQL Database

TODO - Update README

Usage

Requirements

Name Version
terraform >=1.3
azurerm >= 4.0.1

Providers

Name Version
azurerm >= 4.0.1

Modules

No modules.

Resources

Name Type
azurerm_monitor_diagnostic_setting.this resource
azurerm_mssql_database.this resource
azurerm_monitor_diagnostic_categories.this data source

Inputs

Name Description Type Default Required
databases Map of objects to configure MSSQL Database
map(object({
collation = optional(string, "SQL_Latin1_General_CP1_CI_AS")
sku = optional(string, "GP_S_Gen5_1")
max_size_gb = optional(string, "20")
min_capacity = optional(string, "0.5")
auto_pause_delay_in_minutes = optional(number, 60)
create_mode = optional(string, "Default")
creation_source_database_id = optional(string, null)
storage_account_type = optional(string, "ZRS")
}))
{} no
default_retention_days Specifies the number of days to keep in the Threat Detection audit logs. number 3 no
destination_type Log analytics destination type string "Dedicated" no
enable_diagnostic_setting Boolean flag to enabled diagnostic settings for databases bool false no
log_analytics_workspace_id Log Analytics Workspace ID string "" no
server_fqdn FQDN of Azure SQL Server string n/a yes
server_id Id of SQL server string n/a yes
tags tags for resources map(string) {} no

Outputs

Name Description
mssql_database_secrets Map of Database Name to JDBC Connection String
sql_database_id Id of Database
sql_database_max_size Database max size in GB of the Azure SQL Database created.
sql_database_names Database name of the Azure SQL Database created.
sql_server_id Id of SQL server
storage_account_type Storage Account Type

License

Apache 2 Licensed. For more information please see LICENSE

Packages

No packages published

Contributors 6

Languages