Azure Local | Bicep – Logical Networks

Designer (9) (1)
Reading Time: 2 minutes

When you deploy an Azure environment inside a complex enterprise landscape, the last thing you want is a build process that depends on manual steps, tribal knowledge, and someone remembering which portal blade contained the “one important checkbox.” In these scenarios, consistency is not a nice-to-have; it’s a prerequisite for reliability. Infrastructure as Code (IaC) solves that by turning your platform configuration into a repeatable, testable, and reviewable artifact. Instead of rebuilding clusters, networks, identities, and policies by hand every time, you define them once and redeploy them with confidence across development, staging, and production—without configuration drift creeping in between environments.

This is also why an organizational policy of “IaC first” (or even more strictly, “IaC only” for production changes) is a strong governance stance. It establishes that infrastructure changes should be traceable, peer-reviewed, and controlled through the same engineering discipline you apply to application code. It improves auditability because every change is recorded in version control, and it reduces operational risk because deployments become predictable and reproducible. Most importantly, it accelerates delivery: once the baseline is codified, teams spend less time redoing platform work and more time improving it.

Azure Bicep is an ideal way to implement this approach in Azure because it is declarative, readable, and compiles directly to ARM templates, which makes it a first-class citizen in the Azure deployment ecosystem. You can modularize common building blocks—naming standards, tagging, RBAC assignments, monitoring integrations, and networking patterns—so platform teams can publish approved modules while application teams consume them safely and consistently.

A practical example of where this shines is hybrid and edge deployments: you can standardize the creation of networking constructs such as logical networks for an Azure Local cluster, ensuring Arc-managed workloads consistently land in the correct segments. In complex network environments, you don’t want to click this all together.

Bicep

I’ve been developing a reusable Bicep template to streamline deployments that require multiple logical networks, reducing manual effort and improving consistency across environments. To keep the implementation aligned with Microsoft’s recommended patterns, I’m leveraging Azure Verified Modules, which provides standardized, tested building blocks. This approach means future maintenance is minimal: in most cases, you only need to update the module API versions as Azure Local evolves over time, at scale.

https://github.com/GetToThe-Cloud/Website/tree/main/AzureBicep-AzureLocal-LogicalNetworks

Features

  • ✅ Deploys multiple logical networks from a single template
  • ✅ Supports VLAN segmentation
  • ✅ Configurable IP address pools with static or dynamic allocation
  • ✅ DNS server configuration
  • ✅ Default gateway routing
  • ✅ Custom resource tagging
  • ✅ Uses Azure Verified Modules (AVM) for Azure Stack HCI logical networks

Main Parameters

ParameterTypeRequiredDescription
subscriptionIdstringYesAzure subscription ID where resources will be deployed
paramsNetworksarrayYesArray of network configuration objects

Network Configuration Object

Each network object in the paramsNetworks array contains:

ParameterTypeRequiredDescription
parNamestringYesName of the logical network
parResourceGroupNamestringYesResource group containing the custom location
parLocationstringYesAzure region (e.g., ‘westeurope’)
parSubscriptionIdstringYesAzure subscription ID
parExtendedLocationNamestringYesName of the custom location (Azure Stack HCI cluster)
parVSwitchNamestringYesName of the virtual switch on the cluster
parAddressPrefixstringYesIP address prefix in CIDR notation (e.g., ‘172.16.1.0/24’)
parVlanintegerYesVLAN ID for network segmentation (use 0 for untagged)
parIpAllocationMethodstringYesIP allocation method (‘Static’ or ‘Dynamic’)
parDnsServersarrayYesArray of DNS server IP addresses
parDefaultGatewaystringYesDefault gateway IP address
parIpPoolsarrayYesArray of IP pool objects with ‘start’ and ‘end’ properties
parTagsobjectNoResource tags as key-value pairs

Share and Enjoy !

Shares
Designer (23)

Stay close to the action—follow GetToThe.Cloud across social!
Deep dives and hands‑on how‑tos on Azure Local, hybrid cloud, automation, PowerShell/Bicep, AVD + FSLogix, image pipelines, monitoring, networking, and resilient design when the internet/Azure is down.

🔗 Our channels
▶️ YouTube: https://www.youtube.com/channel/UCa33PgGdXt-Dr4w3Ub9hrdQ
💼 LinkedIn Group: https://www.linkedin.com/groups/9181126/
✖️ X (Twitter): https://x.com/Gettothecloud
🎵 TikTok: https://www.tiktok.com/@gettothecloud
🐙 GitHub: https://github.com/GetToThe-Cloud/Website
💬 Slack: DM us for an invite
📲 WhatsApp: DM for the community link

We use cookies to personalise content and ads, to provide social media features and to analyse our traffic. We also share information about your use of our site with our social media, advertising and analytics partners. View more
Cookies settings
Accept
Privacy & Cookie policy
Privacy & Cookies policy
Cookie name Active

Who we are

Our website address is: https://www.gettothe.cloud

Comments

When visitors leave comments on the site we collect the data shown in the comments form, and also the visitor’s IP address and browser user agent string to help spam detection. An anonymized string created from your email address (also called a hash) may be provided to the Gravatar service to see if you are using it. The Gravatar service privacy policy is available here: https://automattic.com/privacy/. After approval of your comment, your profile picture is visible to the public in the context of your comment.

Media

If you upload images to the website, you should avoid uploading images with embedded location data (EXIF GPS) included. Visitors to the website can download and extract any location data from images on the website.

Cookies

If you leave a comment on our site you may opt-in to saving your name, email address and website in cookies. These are for your convenience so that you do not have to fill in your details again when you leave another comment. These cookies will last for one year. If you visit our login page, we will set a temporary cookie to determine if your browser accepts cookies. This cookie contains no personal data and is discarded when you close your browser. When you log in, we will also set up several cookies to save your login information and your screen display choices. Login cookies last for two days, and screen options cookies last for a year. If you select "Remember Me", your login will persist for two weeks. If you log out of your account, the login cookies will be removed. If you edit or publish an article, an additional cookie will be saved in your browser. This cookie includes no personal data and simply indicates the post ID of the article you just edited. It expires after 1 day.

Embedded content from other websites

Articles on this site may include embedded content (e.g. videos, images, articles, etc.). Embedded content from other websites behaves in the exact same way as if the visitor has visited the other website. These websites may collect data about you, use cookies, embed additional third-party tracking, and monitor your interaction with that embedded content, including tracking your interaction with the embedded content if you have an account and are logged in to that website.

Who we share your data with

If you request a password reset, your IP address will be included in the reset email.

How long we retain your data

If you leave a comment, the comment and its metadata are retained indefinitely. This is so we can recognize and approve any follow-up comments automatically instead of holding them in a moderation queue. For users that register on our website (if any), we also store the personal information they provide in their user profile. All users can see, edit, or delete their personal information at any time (except they cannot change their username). Website administrators can also see and edit that information.

What rights you have over your data

If you have an account on this site, or have left comments, you can request to receive an exported file of the personal data we hold about you, including any data you have provided to us. You can also request that we erase any personal data we hold about you. This does not include any data we are obliged to keep for administrative, legal, or security purposes.

Where we send your data

Visitor comments may be checked through an automated spam detection service.
Save settings
Cookies settings