feat(external_dns): support azure-private-dns provider#369
Merged
Conversation
Accepts dns_provider_name = "azure-private-dns" in addition to "azure". Both providers share the same auth, secret mount, and ServiceAccount wiring — only external-dns chart's `provider.name` differs — so the azure_config block now templates the provider name from the input and provider_configs maps both keys to the same config. Validation preconditions and the kubernetes_secret_v1 count condition were extended from `dns_provider_name == "azure"` to a shared `azure_family_active` local that matches both providers. Unblocks callers managing Azure Private DNS zones (Microsoft.Network/ privateDnsZones), which the upstream external-dns binary handles via a separate provider name from the public DNS one. Previously such callers had to maintain their own helm_release block.
sebastiancorrea81
approved these changes
May 26, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds
azure-private-dnsas a supported value fordns_provider_name, alongside the existingazure. Both share the same auth, secret mount, and ServiceAccount wiring — only the external-dns chart'sprovider.namediffers.Why
Azure exposes Public DNS and Private DNS as two distinct ARM resource types (
Microsoft.Network/dnszonesvsMicrosoft.Network/privateDnsZones), and upstream external-dns ships two separate provider implementations (azurevsazure-private-dns) — you cannot manage Private DNS zones viaprovider: azure. AWS and OCI don't have this split (they use flags on the same provider), which is why no symmetric change is needed for those clouds.Until now, callers needing Private DNS zone management had to maintain their own
helm_releaseblock. This PR closes that gap.Changes
variables.tf—dns_provider_namevalidation extended to accept"azure-private-dns"locals.tf—azure_family_activehelper;azure_config.provider.nametemplated from the input;provider_configsmaps both keys to the same configsecret.tf— Azure secret count condition extended to the familyvalidation.tf— Azure preconditions extended to fire for both providersNet diff: 4 files, +27 / -21 lines. Callers passing
dns_provider_name = "azure"get exactly the same Helm Values output as before — bumping the ref is a no-op for them.Usage
Instantiate the module a second time for Private DNS:
The companion IAM module needs
role_definition_name = "Private DNS Zone Contributor"scoped to the private zone.