Not able to locate storage account although I have provided resource block for storage account creation

Not able to locate storage account although I have provided resource block for storage account creation while creating blob storage in azure cloud.



Please suggest. Thanks.

Firstly it is quite hard to answer questions where things are in screenshots. It is much easier if you copy & paste the text directly.

In the first image there is an error saying the storage account name is already in use. If that is the issue you either need to choose a different name, remove the existing resource from Azure or do a terraform import.

I am not saying that this is the solution, but, I noticed that when I ran az storage account list without specifying the subscription, it returned an empty list [], so this left me thinking that maybe is the same for azurerm, specially because I use 3 different subscriptions.

So, I explicitly added the tenant and subscription ids to the setup of the azurerm and it seems to be working for me now. It would be good if someone else could make the test on their side to see if this consistently fixes the issue.

provider "azurerm" {
  tenant_id       = var.tenant_id
  subscription_id = var.subscription_id

  features {...}
}