avm-res-documentdb-databaseaccount
Azure/avm-res-documentdb-databaseaccount/azurerm
Terraform Azure Verified Resource Module for CosmosDB Database Account
Terraform Azure Cosmos DB Module This Terraform module is designed to create Azure Cosmos DB accounts, its related resources and APIs. > [!WARNING] > Major version Zero (0.y.z) is for initial development. Anything MAY change at any time. A module SHOULD NOT be considered stable till at least it is major version one (1.0.0) or greater. Changes will always be via new versions being published and no changes will be made to existing published versions. For more details please go to Features Creation of accounts with NoSQL API with its databases and containers. Creation of accounts with Gremlin API with its databases and graphs. EntraID authentication instead of access keys Support for customer-managed keys. Enable private endpoint, providing secure access over a private network. Enable diagnos
| Name | Type | Description | Default |
|---|---|---|---|
| location | string | Specifies the supported Azure location where the resource exists. Changing thi | required |
| resource_group_name | string | The name of the resource group in which to create this resource. Changing th | required |
| name | string | Specifies the name of the CosmosDB Account. Changing this forces a new resourc | required |
| consistency_policy | object({ max_interval_in_s | Defaults to `{}`. Used to define the consistency policy for this CosmosDB acco | {} |
| free_tier_enabled | bool | Defaults to `false`. Enable the Free Tier pricing option for this Cosmos DB acco | false |
| geo_locations | set(object({ location | Default to the region where the account was deployed with zone redundant enabl | null |
| customer_managed_key | object({ key_name | Defaults to `null`. Ignored for Basic and Standard. Defines a customer managed | null |
| diagnostic_settings | map(object({ name | Defaults to `{}`. A map of diagnostic settings to create. The map key is delib | {} |
| tags | map(string) | Defaults to `{}`. A mapping of tags to assign to the resource. These tags will | null |
| access_key_metadata_writes_enabled | bool | Defaults to `false`. Is write operations on metadata resources (databases, conta | false |
| analytical_storage_config | object({ schema_type = str | Defaults to `null`. Configuration related to the analytical storage of this ac | null |
| analytical_storage_enabled | bool | Defaults to `false`. Enable Analytical Storage option for this Cosmos DB account | false |
| local_authentication_disabled | bool | Defaults to `true`. Ignored for non SQL APIs accounts. Disable local authenticat | true |
| enable_telemetry | bool | Defaults to `true`. This variable controls whether or not telemetry is enabled | true |
| automatic_failover_enabled | bool | Defaults to `true`. Enable automatic failover for this Cosmos DB account. | true |
| cors_rule | object({ allowed_headers | Defaults to `null`. Configures the CORS rule for this Cosmos DB account. - | null |
| gremlin_databases | map(object({ name = string | Defaults to `{}`. Manages Gremlin Databases within a Cosmos DB Account. - ` | {} |
| private_endpoints_manage_dns_zone_group | bool | Default to true. Whether to manage private DNS zone groups with this module. If | true |
| minimal_tls_version | string | Defaults to `Tls12`. Specifies the minimal TLS version for the CosmosDB account. | "Tls12" |
| network_acl_bypass_for_azure_services | bool | Defaults to `false`. If Azure services can bypass ACLs. | false |
| virtual_network_rules | set(object({ subnet_id = s | Defaults to `[]`. Used to define which subnets are allowed to access this Cosm | [] |
| capabilities | set(object({ name = string | Defaults to `[]`. The capabilities which should be enabled for this Cosmos DB | [] |
| private_endpoints | map(object({ subnet_resour | Default to `{}`. A map of private endpoints to create. The map key is delibera | {} |
analytical_storage — The analytical storage configuration for the CosmosDB Account.backup — The backup configuration for the CosmosDB Account.free_tier_enabled — Whether the free tier is enabled for the CosmosDB Account.location — The location/region where the CosmosDB Account is created.partition_merge_enabled — Whether partition merge is enabled for the CosmosDB Account.resource_private_endpoints_application_security_group_association — The IDs of the private endpoint application security group associations created.resource_role_assignments — A map of the role assignments created, with the assignment key as the map key and the assignment valsql_databases — A map of the SQL databases created, with the database name as the key and the database ID, containeridentity — The managed identity configuration for the CosmosDB Account.minimal_tls_version — The minimal TLS version for the CosmosDB Account.mongo_databases — A map of the MongoDB databases created, with the database name as the key and the database id and comongo_server_version — The MongoDB server version for the CosmosDB Account.access_key_metadata_writes_enabled — Whether access key metadata writes are enabled for the CosmosDB Account.cosmosdb_sql_connection_strings — The SQL connection strings for the CosmosDB Account.read_endpoints — A list of read endpoints available for this CosmosDB account.resource_private_endpoints — A map of the management locks created, with the lock name as the key and the lock ID as the value.analytical_storage_enabled — Whether analytical storage is enabled for the CosmosDB Account.capabilities — The capabilities enabled for the CosmosDB Account.cosmosdb_mongodb_connection_strings — The MongoDB connection strings for the CosmosDB Account.key_vault_key_id — The Key Vault key ID used for encryption.kind — The kind of the CosmosDB Account (GlobalDocumentDB, MongoDB, Parse).multiple_write_locations_enabled — Whether multiple write locations are enabled for the CosmosDB Account.resource_diagnostic_settings — A map of the diagnostic settings created, with the diagnostic setting name as the key and the diagnoresource_id — The resource ID of the cosmos db account created.consistency_policy — The consistency policy configuration for the CosmosDB Account.local_authentication_disabled — Whether local authentication is disabled for the CosmosDB Account.name — The name of the cosmos db account created.public_network_access_enabled — Whether public network access is enabled for the CosmosDB Account.write_endpoints — A list of write endpoints available for this CosmosDB account.automatic_failover_enabled — Whether automatic failover is enabled for the CosmosDB Account.