Skip to content

feat: add IP formatting function for Azure Storage Firewall#7

Merged
bhavink merged 1 commit into
bhavink:mainfrom
conraddd:feat/ip-conversion-azure-storage-firewall-automation
Jun 2, 2026
Merged

feat: add IP formatting function for Azure Storage Firewall#7
bhavink merged 1 commit into
bhavink:mainfrom
conraddd:feat/ip-conversion-azure-storage-firewall-automation

Conversation

@conraddd

@conraddd conraddd commented Jun 2, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Adds format_ips_for_azure_storage() to the Azure Function App example in docs/firewall-automation-guide.md — expands /31 and /32 CIDRs into individual host IPs before applying Storage Account network rules; leaves wider prefixes as CIDR strings. And wires the helper into the optional Storage Account sync path
  • Updates the doc on how Azure SDK handles the /31 and /32 CIDRs

Why

Azure Storage network rules do not accept the /31 and /32 as CIDR strings, even in the Azure SDK

This is documentation-only (same scope as the guide's existing Function App sample). The Terraform CIDR module from PR #2 is unchanged — customers who use source_files with -outbound.txt and write their own azurerm_storage_account_network_rules may still need equivalent /31//32 handling in their apply logic; this PR shows the pattern in the Azure automation walkthrough.

Test plan

  • Test behavior locally (Azure uksouth outbound):
    • 172.186.31.34/31172.186.31.34, 172.186.31.35
    • 51.140.203.27/3251.140.203.27

Backward compatibility

  • No changes to published TXT feeds, update_outputs.py, or terraform/.
  • Existing combined and direction-scoped URLs are unchanged; this only improves the copy-paste Azure Function example and its Storage Account notes.

- Introduced `format_ips_for_azure_storage` function to convert `/31` and `/32` CIDRs into individual IP addresses for compatibility with Azure Storage Firewall.
- Updated `databricks_ip_sync` function to utilize the new formatting function for IP comparison.
- Revised documentation to clarify the handling of CIDR formats in the context of Azure Storage Account network rules.
@bhavink bhavink merged commit c7b0e8a into bhavink:main Jun 2, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants