Add 101-standard-service-endpoint-storage quickstart sample - #488
Draft
asudbring wants to merge 2 commits into
Draft
Add 101-standard-service-endpoint-storage quickstart sample#488asudbring wants to merge 2 commits into
asudbring wants to merge 2 commits into
Conversation
Adds a Terraform quickstart that deploys a virtual network with a subnet that has a Microsoft.Storage service endpoint, a Standard static public IP that serves as the network identifier, a Linux virtual machine, and an Azure Storage account restricted to the subnet. Test-deployed and torn down against two Azure subscriptions in eastus2. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
Author
|
Companion Terraform quickstart article PR: MicrosoftDocs/azure-docs-pr#319044 (internal). The article references this sample via |
asudbring
marked this pull request as draft
August 5, 2026 03:53
…dpoint The original sample configured a basic virtual network service endpoint (subnet service_endpoints plus storage network rules) and named it after the standard service endpoint feature. Those are different features. A standard service endpoint requires a network identifier associated with the subnet service endpoint, and a network security perimeter that authorizes that identifier with an IP-based inbound access rule. None of that was present. Changes: - Rename sample to 101-standard-service-endpoint-storage - Associate a public IP address as the service endpoint networkIdentifier via azapi (the azurerm provider does not expose this property) - Add public IP prefix backing the network identifier - Add network security perimeter, profile, association, and inbound access rule matching the network identifier prefix - Add NAT gateway for VM outbound connectivity - Add storage file share for connectivity validation - Drop subnet-scoped storage network rules; the perimeter governs access - Pin azapi to ~>2.0 to match the object-syntax body already in use - Default location to eastus2 Verified: terraform apply and destroy against a subscription with the AllowServiceEndpointNetworkIdentifier feature registered. 21 resources created and destroyed. Subnet serviceEndpoints reported networkIdentifier associated with provisioningState Succeeded.
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.
Adds a quickstart sample for a standard service endpoint for Azure Storage.
A standard service endpoint connects IaaS workloads to PaaS resources using a network identifier (a public IP address) and a network security perimeter, rather than subnet-scoped ACLs. This addresses the scale limits of basic service endpoints: one public IP can represent many virtual networks and subnets in the same region and subscription.
Sample directory:
quickstart/101-standard-service-endpoint-storage/Resources
azapi)Microsoft.StorageNotes for reviewers
azapiprovider because the service endpointnetworkIdentifierproperty is not exposed byazurerm. It is available in the stable ARM APIMicrosoft.Network/virtualNetworks/subnets@2025-07-01.AllowServiceEndpointNetworkIdentifierfeature flag. The readme documents the self-serve registration commands. CI will need this feature registered on the test subscription, or this sample will fail to deploy. Happy to hold this PR until the feature is GA if that is preferred.Learningmode (logs, does not block), which is the recommended starting posture.nsp_access_modecan be set toEnforced.eastus2.Verification
terraform applyandterraform destroyrun against a subscription with the preview feature registered.{ "service": "Microsoft.Storage", "networkIdentifier": { "id": ".../providers/Microsoft.Network/publicIPAddresses/public-ip-1" }, "provisioningState": "Succeeded" }assoc-storage, modeLearning, stateSucceeded.allow-se-standard, directionInbound, prefix matching the allocated network identifier range.terraform fmtapplied;terraform validatepasses.Revision history
The initial revision of this PR configured a basic virtual network service endpoint (
subnet.service_endpointsplus storage network rules) and named it after the standard service endpoint feature. Those are different features. The sample has been rewritten to implement the standard service endpoint, and the directory renamed accordingly.