Closed itnachol closed 6 months ago
This error is a reflection of API behavior: the Equinix Metal API was updated to require VLANs to be specified when creating a connection and to prevent updating VLANs when updating a connection. The provider was updated to flag these issues during plan instead of waiting for an API error. That provider change was included in the v1.32.0 release.
Terraform Version
v1.6.3
Equinix Provider Version
1.31
Effected Terraform Resources
equinix_metal_connection
Terraform Config Files
resource "equinix_metal_connection" "metal_vc_connection" { name = "metal-vrf-to-azure" project_id = var.metal_project_id type = "shared" redundancy = "redundant" metro = var.metro speed = "50Mbps" service_token_type = "a_side" contact_email = var.notification_email }
Debug Output
No response
Panic Output
No response
Expected Behavior
I has been working so far, same code
Actual Behavior
equinix_metal_connection.metal_vc_connection: Creating... ╷ │ Error: Error creating Metal Connection │ │ with equinix_metal_connection.metal_vc_connection, │ on main.tf line 164, in resource "equinix_metal_connection" "metal_vc_connection": │ 164: resource "equinix_metal_connection" "metal_vc_connection" { │ │ Could not create a shared Metal Connection: POST https://api.equinix.com/metal/v1/projects/bd27e9bf-0df2-4187-a2ad-a8cd1e79fa26/connections: 422 VLAN(s) must be set │ on creation for Fabric VCs.
Steps to Reproduce
just create a new metal connection aSide