Azure / Azure/terraform

Compute Instance with no Public IP fails to provision

Open
#85 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
HCL
Stars
925
Forks
930
Avg merge
4d 15h
Merged PRs (30d)
5

Description

## Context (Environment)

I'm trying to manually create a compute instance with **no public IP address** (since it's not possible to do it with Terraform). After setting up a private Azure ML workspace following this template [201-machine-learning-moderately-secure](https://github.com/Azure/terraform/tree/master/quickstart/201-machine-learning-moderately-secure)

### Terraform (and AzureRM Provider) Version
terraform v0.14.0
azurerm v2.96.0

## Current Behavior

Provisioning fails with this error:
```
Provisioning error
The specified subnet /subscriptions/[REDACTED]/resourceGroups/[REDACTED]/providers/Microsoft.Network/virtualNetworks/[REDACTED]/subnets/snet-training-dev-westeurope has PrivateLinkServiceNetworkPolicies or PrivateEndpointNetworkPolicies enabled. Please disable them to provision cluster/instance with no public IP. Please read this document for more details: https://aka.ms/AMLPLNetPolicies
```

Provisioning Compute Instance with public IP address completes successfully.

## Possible Solution

I have tried every combination of PrivateLinkServiceNetworkPolicies or PrivateEndpointNetworkPolicies on the training subnet. No luck!

Here's my training Subnet block
```hcl
resource "azurerm_subnet" "snet_training" {
name = "snet-training-${var.deploy_target}-${var.machine_learning_location}"
resource_group_name = data.azurerm_virtual_network.existing_mlw_vnet.resource_group_name
virtual_network_name = data.azurerm_virtual_network.existing_mlw_vnet.name
address_prefixes = var.snet_training_addr_prefixes
enforce_private_link_endpoint_network_policies = true
enforce_private_link_service_network_policies = false
}
```

## Steps to Reproduce

1. [201-machine-learning-moderately-secure](https://github.com/Azure/terraform/tree/master/quickstart/201-machine-learning-moderately-secure)

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the 201-machine-learning-moderately-secure template and the reported Terraform v0.14.0 and AzureRM v2.96.0 configuration. Review the training subnet's private-link policy settings and reproduce provisioning with no public IP. Done means the documented configuration provisions the compute instance without the reported network-policy error.

Written by the indexing model from the issue text.

Assessment

Tech stack
azure
Domain
cloud, infrastructure
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.