Search code examples
azureterraformazure-machine-learning-serviceazure-rm

How to create azure machine learning resource using terraform resource providers?


I wants to create azure machine learning workspace using terraform scripts.Is there any terraform provider to achieve this.


Solution

  • In the meantime Microsoft has added a Terraform resource for ML Workspace in the Azure Provider. This should make any custom scripting obsolete.

    https://www.terraform.io/docs/providers/azurerm/r/machine_learning_workspace.html

    resource "azurerm_machine_learning_workspace" "example" {
      name                    = "example-workspace"
      location                = azurerm_resource_group.example.location
      resource_group_name     = azurerm_resource_group.example.name
      application_insights_id = azurerm_application_insights.example.id
      key_vault_id            = azurerm_key_vault.example.id
      storage_account_id      = azurerm_storage_account.example.id
    
      identity {
        type = "SystemAssigned"
      }
    }