Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generate uniqueData for Private Link resources in an idempotent manner #748

Merged

Conversation

BrandonSharp
Copy link
Contributor

Description

The current method for generating uniqueData for use in naming resources prevents idempotent deployment because an attempt to create a new AMPLS resource results in a conflict with the previous one. This additionally leads to multiple private endpoints getting created, which could eventually exhaust IP space in the subnet over time if deployed enough times.

I propose that if this is generated using the uniqueString Bicep function instead, the random string will be generated in a repeatable manner, provided future deployments are both to the same subscription, and with the same deployment name. Manual testing in an Azure Gov subscription seems good as far as I can tell.

Relevant change is to L22. The remainder are corrections to whitespace by the Bicep plugin in VS Code.

Issue reference

The issue this PR will close: #700

Checklist

Please make sure you've completed the relevant tasks for this PR out of the following list:

  • All acceptance criteria in the backlog item are met
  • The documentation is updated to cover any new or changed features
  • Manual tests have passed
  • Relevant issues are linked to this PR

@BrandonSharp BrandonSharp requested a review from a team as a code owner September 9, 2022 19:25
@ghost
Copy link

ghost commented Sep 9, 2022

CLA assistant check
All CLA requirements met.

@lisamurphy-msft
Copy link
Contributor

/azp run

@azure-pipelines
Copy link

Azure Pipelines could not run because the pipeline triggers exclude this branch/path.

@lisamurphy-msft
Copy link
Contributor

Greetings @BrandonSharp Thank you for your PR. Will review and test momentarily.

@lisamurphy-msft lisamurphy-msft merged commit a3b5ca2 into Azure:main Sep 9, 2022
@BrandonSharp BrandonSharp deleted the 700-uniquestring-implementation branch September 9, 2022 20:02
@lisamurphy-msft lisamurphy-msft added bug Something isn't working core New feature or request labels Sep 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working core New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Multiple private link scopes created for same LAWS in MLZ Bicep on re-deployment
2 participants