So If I import state file and store it in Azure Storage and give path to this state file in the Azure DevOps , will it create a new state file or pick this one ?
You should be giving the configuring location of the tfstate file in your terraform script rather than Azure DevOps as below and Configure Azure DevOps Pipelines to run:
So If I import state file and store it in Azure Storage and give path to this state file in the Azure DevOps , will it create a new state file or pick this one ?
You should be giving the configuring location of the tfstate file in your terraform script rather than Azure DevOps as below and Configure Azure DevOps Pipelines to run:
terraform {
backend "azurerm" {
resource_group_name = "StorageAccount-ResourceGroup"
storage_account_name = "abcd1234"
container_name = "tfstate"
key = "prod.terraform.tfstate"
}
}