Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Resources: azurerm_subnet_network_security_group_association / azurerm_subnet_route_table_association #1933

Merged
merged 5 commits into from
Oct 13, 2018

Conversation

tombuildsstuff
Copy link
Contributor

This PR introduces two new Virtual Resources for linking Subnets to Network Security Groups (azurerm_subnet_network_security_group_association) and Route Tables (azurerm_subnet_route_table_association). As a part of this PR, the fields route_table_id and network_security_group_id within the azurerm_subnet resource have been made Computed (to allow them to be set via the new resource) and Deprecated (in favour of the new resources).

Separating these associations out from the main Subnet resource means we no longer have to check the config during the deletion (which may not be present) - such that this should alleviate some hard to reproduce deletion bugs.

Copy link
Collaborator

@katbyte katbyte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 💯

```
$ acctests azurerm TestAccAzureRMSubnetRouteTableAssociation
=== RUN   TestAccAzureRMSubnetRouteTableAssociation_basic
--- PASS: TestAccAzureRMSubnetRouteTableAssociation_basic (145.86s)
=== RUN   TestAccAzureRMSubnetRouteTableAssociation_deleted
--- PASS: TestAccAzureRMSubnetRouteTableAssociation_deleted (103.94s)
PASS
ok  	github.com/terraform-providers/terraform-provider-azurerm/azurerm	250.163s
```
```
$ acctests azurerm TestAccAzureRMSubnetNetworkSecurityGroupAssociation_
=== RUN   TestAccAzureRMSubnetNetworkSecurityGroupAssociation_basic
--- PASS: TestAccAzureRMSubnetNetworkSecurityGroupAssociation_basic (129.21s)
=== RUN   TestAccAzureRMSubnetNetworkSecurityGroupAssociation_deleted
--- PASS: TestAccAzureRMSubnetNetworkSecurityGroupAssociation_deleted (99.74s)
PASS
ok  	github.com/terraform-providers/terraform-provider-azurerm/azurerm	229.367s
```
@tombuildsstuff tombuildsstuff modified the milestones: 1.18.0, 1.17.0 Oct 13, 2018
@tombuildsstuff
Copy link
Contributor Author

Tests pass:

screenshot 2018-10-12 at 23 23 51

@ghost
Copy link

ghost commented Mar 6, 2019

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 [email protected]. Thanks!

@ghost ghost locked and limited conversation to collaborators Mar 6, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants