Skip to content

Commit

Permalink
make shared_key optional and computed again (#27560)
Browse files Browse the repository at this point in the history
  • Loading branch information
stephybun authored Oct 4, 2024
1 parent 4d5af74 commit 2ab6e9d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,10 @@ func resourceVirtualNetworkGatewayConnection() *pluginsdk.Resource {
},

"shared_key": {
Type: pluginsdk.TypeString,
Required: true,
Type: pluginsdk.TypeString,
Optional: true,
// NOTE: O+C the API generates a key for the user if not supplied
Computed: true,
Sensitive: true,
},

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -478,7 +478,6 @@ resource "azurerm_virtual_network_gateway_connection" "test" {
type = "IPsec"
virtual_network_gateway_id = azurerm_virtual_network_gateway.test.id
local_network_gateway_id = azurerm_local_network_gateway.test.id
shared_key = "4-v3ry-53cr37-1p53c-5h4r3d-k3y"
}
`, data.RandomInteger, data.Locations.Primary)
}
Expand Down Expand Up @@ -586,7 +585,6 @@ resource "azurerm_virtual_network_gateway_connection" "test" {
express_route_circuit_id = azurerm_express_route_circuit.test.id
authorization_key = azurerm_express_route_circuit_authorization.test.authorization_key
routing_weight = "0"
shared_key = "4-v3ry-53cr37-1p53c-5h4r3d-k3y"
}
`, data.RandomInteger, data.Locations.Primary, data.RandomInteger, data.RandomInteger)
}
Expand Down Expand Up @@ -1666,8 +1664,6 @@ resource "azurerm_virtual_network_gateway_connection" "test" {
egress_nat_rule_ids = [azurerm_virtual_network_gateway_nat_rule.test.id]
ingress_nat_rule_ids = [azurerm_virtual_network_gateway_nat_rule.test2.id]
shared_key = "4-v3ry-53cr37-1p53c-5h4r3d-k3y"
}
`, data.RandomInteger, data.Locations.Primary, data.RandomInteger, data.RandomInteger, data.RandomInteger, data.RandomInteger, data.RandomInteger, data.RandomInteger, data.RandomInteger)
}
Expand Down

0 comments on commit 2ab6e9d

Please sign in to comment.