Skip to content

Conversation

stef-p
Copy link
Contributor

@stef-p stef-p commented Jun 15, 2024

This PR enables the skip_provider_registration field in azurerm provider as documented in:

https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/resources/resource_provider_registration

The default behaviour will set the skip_provider_registration = false

Copy link
Contributor

@Carus11 Carus11 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Simple enough, preserves existing functionality. lgtm. The commit is missing the DCO signoff which is required as part of the contribution guidelines.
Just curious however, in generic terms what was the situation which drove this enhancement? Is it something that should be considered broadly?

@Carus11
Copy link
Contributor

Carus11 commented Feb 11, 2025

Does this address the issue in #397 ?

@iadomi iadomi changed the base branch from main to staging March 26, 2025 15:06
@iadomi
Copy link
Contributor

iadomi commented Mar 26, 2025

@stef-p Thank you for your contribution and we are currently looking over your PR. But going back to @Carus11's question, what was the situation which drove this enhancement and is it something that should be considered broadly considering in the doc you referenced it states that "if in doubt we strongly recommend letting Terraform register these for you" in regards to Resource Providers

@iadomi
Copy link
Contributor

iadomi commented Mar 26, 2025

@stef-p After reviewing your PR a little more and attempting to test your changes locally, we noticed that the skip_provider_registration property has since been deprecated and will be removed in v5.0.

Warning: Argument is deprecated

│ with provider["registry.terraform.io/hashicorp/azurerm"],
│ on main.tf line 17, in provider "azurerm":
│ 17: skip_provider_registration = var.skip_provider_registration

│ This property is deprecated and will be removed in v5.0 of the AzureRM
│ provider. Please use the resource_provider_registrations property
│ instead.

│ (and one more similar warning elsewhere)

Digging at bit deeper it seems that this deprecation was implemented in v4.0.0 (https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/guides/4.0-upgrade-guide#improved-resource-provider-registration) which took place around August 22, 2024 which is after your PR was created.

If you are still interested in this enhancement, we will gladly work with on that but please consider modifying your changes to match the current implementation (https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs/guides/4.0-upgrade-guide#improved-resource-provider-registration). Otherwise, if we don't get a response back from you within the next 30 days we will mark this PR stale and will be closed

@stef-p
Copy link
Contributor Author

stef-p commented Apr 16, 2025

@stef-p Thank you for your contribution and we are currently looking over your PR. But going back to @Carus11's question, what was the situation which drove this enhancement and is it something that should be considered broadly considering in the doc you referenced it states that "if in doubt we strongly recommend letting Terraform register these for you" in regards to Resource Providers

I think skip registration was required because the customer has BYO defined for many resources. They have defined aks_uai_name and the managed identity is created out of band from terraform. Terraform was failing because it was expecting to create the managed identity during its run.

@stef-p
Copy link
Contributor Author

stef-p commented Apr 16, 2025

@stef-p Thank you for your contribution and we are currently looking over your PR. But going back to @Carus11's question, what was the situation which drove this enhancement and is it something that should be considered broadly considering in the doc you referenced it states that "if in doubt we strongly recommend letting Terraform register these for you" in regards to Resource Providers

I think skip registration was required because the customer had several BYO resources. They have defined aks_uai_name and the managed identity is created out of band from terraform. Terraform was failing because it was expecting to create the managed identity during its run.

@saschjmil
Copy link
Contributor

Hey @stef-p, the issues you are describing sound similar to #450, which is being fixed in PR #477. Do you think that #477 would solve your issue?

@stef-p stef-p changed the title Skip provider registration feat: Skip provider registration Apr 16, 2025
@stef-p stef-p marked this pull request as draft April 16, 2025 19:11
@stef-p
Copy link
Contributor Author

stef-p commented Apr 17, 2025

Hey @stef-p, the issues you are describing sound similar to #450, which is being fixed in PR #477. Do you think that #477 would solve your issue?

I don't think so, in our scenario we are using an existing identity.

Stef Pierre added 2 commits April 17, 2025 15:20
I, Stef Pierre <[email protected]>, hereby add my Signed-off-by to this commit: a654571
I, Stef Pierre <[email protected]>, hereby add my Signed-off-by to this commit: 75371b3

Signed-off-by: Stef Pierre <[email protected]>
Signed-off-by: Stef Pierre <[email protected]>
I, Stef Pierre <[email protected]>, hereby add my Signed-off-by to this commit: fdcf446

Signed-off-by: Stef Pierre <[email protected]>
@stef-p stef-p marked this pull request as ready for review April 17, 2025 19:23
@saschjmil saschjmil deleted the branch sassoftware:main May 8, 2025 18:30
@saschjmil saschjmil closed this May 8, 2025
@saschjmil saschjmil reopened this May 8, 2025
@saschjmil saschjmil changed the base branch from staging to main May 8, 2025 18:44
@saschjmil
Copy link
Contributor

Hey @stef-p, sorry for closing and re-opening your PR. I deleted the staging branch, which closed all PR's targeting it. I've updated your PR to point to the main branch.

@iadomi
Copy link
Contributor

iadomi commented Jun 2, 2025

@stef-p
Before we can move forward with you PR, it needs to meet our Pull Request Requirements. The notable thing there is that we require unit and/or integration test. You can refer to our Testing Philosophy for guidance but we would more be more than happy to help and advise you on that. You can also refer to another PR that you suggested in #389 and #469 for a unit test example as reference for all the changes we would need for this PR. Note the updates to the /docs/CONFIG-VARS.md
and variables.tf and main.tf under /modules/azure_aks

Copy link

github-actions bot commented Jul 3, 2025

This PR is stale because it has been open 30 days with no activity.

@github-actions github-actions bot added the stale Open for 30 days with no activity label Jul 3, 2025
@abhikumar2204 abhikumar2204 changed the title feat: Skip provider registration feat: skip provider registration Sep 17, 2025
@abhikumar2204 abhikumar2204 reopened this Sep 17, 2025
@abhikumar2204
Copy link
Contributor

Hi @stef-p @Carus11

Could you please check the failure for PR Conventional Commit Validation / validate-pr-title (pull_request), post this we will be able to merge this.

Also let us know if this still needed to be a part of this Repo, or we could stale this and Close without merging.

Thanks!

@github-actions github-actions bot removed the stale Open for 30 days with no activity label Sep 19, 2025
@abhikumar2204 abhikumar2204 added the stale Open for 30 days with no activity label Oct 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stale Open for 30 days with no activity
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants