hashicorp / terraform-provider-azurerm

Terraform provider for Azure Resource Manager
https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs
Mozilla Public License 2.0
4.53k stars 4.6k forks source link

Global parameter is ignored in azurerm_data_factory when vsts_configuration block is defined #17507

Open KurtPetteloot opened 2 years ago

KurtPetteloot commented 2 years ago

Is there an existing issue for this?

Community Note

Terraform Version

1.2.3

AzureRM Provider Version

3.12.0

Affected Resource(s)/Data Source(s)

azurerm_data_factory

Terraform Configuration Files

resource "azurerm_resource_group" "rg" {
  name     = "rg-my-resource-group-kpe"
  location = "westeurope"
}

resource "azurerm_data_factory" "my_data_factory" {
  name                = "adf-my-data-factory-kpe-002"
  location            = azurerm_resource_group.rg.location
  resource_group_name = azurerm_resource_group.rg.name
  identity {
    type = "SystemAssigned"
  }
  global_parameter {
    name  = "param"
    type  = "String"
    value = "yyyy"
  }
  vsts_configuration {
    account_name    = "the-account"
    branch_name     = "main"
    project_name    = "azure-devops-project"
    repository_name = "azure-devops-repo"
    root_folder     = "/ADF/"
    tenant_id       = "00000000-0000-0000-0000-000000000000"
  }
}

Debug Output/Panic Output

https://gist.github.com/KurtPetteloot/56edd2a8f2cb5c76d53688c2321a4768

Expected Behaviour

Global parameter is created and data factory is connected with azure repo.

Actual Behaviour

Global parameter was not created. Connection with azure repo is ok.

Steps to Reproduce

  1. Adapt the configuration code so that the data factory is created in a valid resource group.
  2. Adapt the vsts_configuration so that ADF can connect with a valid Azure repo.
  3. run: terraform apply
  4. Verify the outcome in the Azure portal:
    • the data factory is created and is connected to the repo
    • the global parameter is not defined (list with global parameters is empty, even after waiting for a few minutes and having done several refreshes ;-))

Remark: The issue seems to occur only if the azurerm_data_factory block contains the vsts_configuration argument. When the vsts_configuration block is removed and terraform apply is executed again, then the global parameter gets created as expected.

Important Factoids

No response

References

No response

dbhaigh commented 1 year ago

Can confirm that this issue is still outstanding as of 3/2/23 and is very annoying

-=A=-

vvvssnarayana commented 1 year ago

Hi, Is there any update on this issue. I could see the global parameter is created when i switch to live mode in data factory. However when i switch to Git mode after configuring using vsts_configuration block, I cannot see the global parameter that is defined in the resource bolck for Data factory

RationalTrip commented 1 year ago

Hi, now 13 of August 2023. Have the same problem.

dan-corneanu commented 11 months ago

I think that when in GIT mode,

If I am correct then this is not a bug.

eric-montufar commented 5 months ago

Have you found any solution for this problem?

nesmoht commented 2 days ago

I have the same issue, any solution?