azurerm_data_factory_linked_service_cosmosdb

Manages a Linked Service (connection) between a CosmosDB and Azure Data Factory using SQL API.

Example Usage

resource "azurerm_resource_group" "example" {
  name     = "example-resources"
  location = "West Europe"
}

data "azurerm_cosmosdb_account" "example" {
  name                = "tfex-cosmosdb-account"
  resource_group_name = "tfex-cosmosdb-account-rg"
}

resource "azurerm_data_factory" "example" {
  name                = "example"
  location            = azurerm_resource_group.example.location
  resource_group_name = azurerm_resource_group.example.name
}

resource "azurerm_data_factory_linked_service_cosmosdb" "example" {
  name             = "example"
  data_factory_id  = azurerm_data_factory.example.id
  account_endpoint = data.azurerm_cosmosdb_account.example.endpoint
  account_key      = data.azurerm_cosmosdb_account.example.primary_key
  database         = "foo"

}

Argument Reference

The following supported arguments are common across all Azure Data Factory Linked Services:

The following supported arguments are specific to CosmosDB Linked Service:

Attributes Reference

In addition to the Arguments listed above - the following Attributes are exported:

Timeouts

The timeouts block allows you to specify timeouts for certain actions:

Import

Data Factory Linked Service's can be imported using the resource id, e.g.

terraform import azurerm_data_factory_linked_service_cosmosdb.example /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/example/providers/Microsoft.DataFactory/factories/example/linkedservices/example