Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

provision azure ad b2c with resources in the tenant

I have the following terraform code :

terraform {
  required_version = ">= 1.1"

  required_providers {
    azurerm = {
      version = ">= 3.0.2"
    }
  }
  backend "azurerm" {}
  
}

provider "azurerm" {
  subscription_id = var.subscription_id
  features {}
}

provider "azurerm" {
    alias = "aad_b2c"
    tenant_id = azurerm_aadb2c_directory.example-b2c.tenant_id
    features {}
}

resource "azurerm_aadb2c_directory" "example-b2c" {
  country_code            = "FR"
  data_residency_location = "Europe"
  display_name            = "example"
  domain_name             = "example.onmicrosoft.com"
  resource_group_name     = azurerm_resource_group.main.name
  sku_name                = "PremiumP1"
}

resource "azuread_application" "demo" {
  provider = azurerm.aad_b2c
  display_name = "demo"
}

I got the following message :
The provider hashicorp/azurerm does not support resource type "azuread_application".

According to the documentation I cannot assigned a value which is an exported attribute to configure my provider. Is there any workarround to create an azure AD B2C tenant and some app registration inside ?

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

>Solution :

Based on the comments.

azuread_application is part of azuread provider, not the azurerm.

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading