Skip to content

Conversation

SebastianClaesson
Copy link

@SebastianClaesson SebastianClaesson commented Feb 11, 2025

Overview/Summary

Pull request fixes;

The Azure Policy Set for "deploy-private-dns-zones" contains a parameter called effect1 which is used for only these azure policy definitions;

DINE-Private-DNS-Azure-EventGridTopics
DINE-Private-DNS-Azure-IoTHubs
DINE-Private-DNS-Azure-EventGridDomains
The parameter should be removed and the parameter effect should be used instead across these three policy definitions.

However the default value of the parameter dnsZoneNames with key 'azureEventGridTopicsPrivateDnsZoneId' is
"privatelink.eventgrid.azure.net"
Reference; azureEventGridTopicsPrivateDnsZoneId

According to the Event grid documentations the expected DNS zone should be in the following format;
..privatelink.eventgrid.azure.net

Reference; https://learn.microsoft.com/en-us/azure/event-grid/network-security#dns-changes-for-private-endpoints

This PR fixes/adds/changes/removes

  1. Removes Effect1 parameter (Effect1 - Parameter #1919)
  2. Changes that the three policies that utilized Effect1 now uses Effect parameter (Effect1 - Parameter #1919)
  3. Updated the parameter for eventgrid topic and domainName to contain regionName (Eventgrid - Topic - Private dns zone policy #1920)

Breaking Changes

  1. Removed a parameter called "Effect1" which will lead to that the policySet needs to be reprovisioned.

Testing Evidence

Using EnterprisePolicyAsCode this is the output; (Proving that a redeploy of the initiative is required)
image
image

The logic works after update (However I do not have any topics or domain names to test on)
image

As part of this Pull Request I have

  • Checked for duplicate Pull Requests
  • Associated it with relevant issues, for tracking and closure.
  • Ensured my code/branch is up-to-date with the latest changes in the main branch
  • Performed testing and provided evidence.
  • Ensured contribution guidance is followed.
  • Updated relevant and associated documentation.
  • Updated the "What's New?" wiki page (located: /docs/wiki/whats-new.md)

@SebastianClaesson SebastianClaesson requested a review from a team as a code owner February 11, 2025 09:49
@SebastianClaesson SebastianClaesson changed the title Removing Effect1 parameter and usage. Replaced with Effect Removing Effect1 parameter and usage. Updated parameter value Feb 11, 2025
Copy link
Member

@Springstone Springstone left a comment

Choose a reason for hiding this comment

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

@SebastianClaesson many thanks for your contribution and apologies it's taken a while to get to this review.

Need a couple of changes please:

  • Increment initiative version to the next major (as this is a breaking change)
  • Move the what's new entry under Policy instead of Tooling
  • Rebuild the deployment payload:

bicep build ./src/templates/initiatives.bicep --outfile ./eslzArm/managementGroupTemplates/policyDefinitions/initiatives.json

@SebastianClaesson
Copy link
Author

@SebastianClaesson many thanks for your contribution and apologies it's taken a while to get to this review.

Need a couple of changes please:

  • Increment initiative version to the next major (as this is a breaking change)
  • Move the what's new entry under Policy instead of Tooling
  • Rebuild the deployment payload:

bicep build ./src/templates/initiatives.bicep --outfile ./eslzArm/managementGroupTemplates/policyDefinitions/initiatives.json

Thanks for the update! :)

  • I've updated the version to 3.0.0
  • Moved the entry to policy under May 2025.
  • Rebuilt the deployment payload

@Springstone Springstone added the Area: Policy 📝 Issues / PR's related to Policy label May 19, 2025
@Springstone Springstone added this to the policy-refresh-fy25-h2 milestone May 19, 2025
@Springstone
Copy link
Member

Springstone commented May 19, 2025

@SebastianClaesson many thanks for the changes. I'll redirect the pull request to Policy-Refresh branch, so we can include it with release testing of the next refresh. Really appreciate your contribution!

If you don't mind resolving the conflicts, that will help get t his merged. You can accept either change for the initiatives.json (hash change doesn't matter), and you should be fine with accepting both changes for whatsnew.md

@Springstone Springstone changed the base branch from main to policy-refresh-h2fy25 May 19, 2025 07:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: Policy 📝 Issues / PR's related to Policy
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants