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

provider/aws: aws_vpn_gateway_route_propagation resource #15137

Merged
merged 1 commit into from
Jun 9, 2017

Conversation

apparentlymart
Copy link
Contributor

This is a separate resource that serves a similar purpose to the propagating_vgws argument on aws_route_table, but allows route propagations to be created independently of the route table, which in
turn allows the VPN gateway to be created after the route table it will contribute to, possibly in a separate Terraform module.

To make this work, propagating_vgws on aws_route_table is now marked as Computed, meaning that it won't try to delete any existing propagation edges if there is no setting for it in configuration at all. This allows the user to choose whether to use the argument or the separate resource, though using both together will not work, as explained in the docs.

This is a slight change in existing behavior, because previously the aws_route_table resource would actively remove any existing route propagation relationships if the argument was not set in config.

This fixes #3424.

This is a separate resource that serves a similar purpose to the
propagating_vgws argument on aws_route_table, but allows route
propagations to be created independently of the route table, which in
turn allows the VPN gateway to be created after the route table it will
contribute to, possibly in a separate Terraform module.

To make this work, propagating_vgws on aws_route_table is now marked
as Computed, meaning that it won't try to delete any existing propagation
edges if there is no setting for it in configuration at all. This allows
the user to choose whether to use the argument or the separate resource,
though using both together will not work, as explained in the docs.
@apparentlymart apparentlymart self-assigned this Jun 7, 2017
@stack72
Copy link
Contributor

stack72 commented Jun 9, 2017

@apparentlymart, LGTM - made 1 change locally which was to fix a vet issue (figured you have your hands full with 0.10.0)

% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSRouteTable_'                                                            ✭
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/06/09 13:51:42 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSRouteTable_ -timeout 120m
=== RUN   TestAccAWSRouteTable_importBasic
--- PASS: TestAccAWSRouteTable_importBasic (77.74s)
=== RUN   TestAccAWSRouteTable_complex
--- PASS: TestAccAWSRouteTable_complex (217.96s)
=== RUN   TestAccAWSRouteTable_basic
--- PASS: TestAccAWSRouteTable_basic (120.01s)
=== RUN   TestAccAWSRouteTable_instance
--- PASS: TestAccAWSRouteTable_instance (183.13s)
=== RUN   TestAccAWSRouteTable_ipv6
--- PASS: TestAccAWSRouteTable_ipv6 (61.81s)
=== RUN   TestAccAWSRouteTable_tags
--- PASS: TestAccAWSRouteTable_tags (163.68s)
=== RUN   TestAccAWSRouteTable_panicEmptyRoute
--- PASS: TestAccAWSRouteTable_panicEmptyRoute (37.75s)
=== RUN   TestAccAWSRouteTable_vpcPeering
--- PASS: TestAccAWSRouteTable_vpcPeering (70.17s)
=== RUN   TestAccAWSRouteTable_vgwRoutePropagation
--- PASS: TestAccAWSRouteTable_vgwRoutePropagation (80.28s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	1012.574s
[stacko@Pauls-MacBook-Pro:~/Code/go/src/github.com/hashicorp/terraform on gh3424-vgw-route-prop]
% make testacc TEST=./builtin/providers/aws TESTARGS='-run=TestAccAWSVPNGatewayRoutePropagation'                                           ✹ ✭
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/06/09 14:10:03 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/aws -v -run=TestAccAWSVPNGatewayRoutePropagation -timeout 120m
=== RUN   TestAccAWSVPNGatewayRoutePropagation_basic
--- PASS: TestAccAWSVPNGatewayRoutePropagation_basic (76.74s)
PASS
ok  	github.com/hashicorp/terraform/builtin/providers/aws	76.777s

@stack72 stack72 merged commit 1aff439 into master Jun 9, 2017
@stack72 stack72 deleted the gh3424-vgw-route-prop branch June 9, 2017 11:14
@apparentlymart
Copy link
Contributor Author

Thanks for the fix, and the merge! 😀

@nwhite-dw
Copy link

I could use this new resource, has it been released?

@ghost
Copy link

ghost commented Apr 8, 2020

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 have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

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

Successfully merging this pull request may close these issues.

vpn route propagation should be on aws_vpn_gateway resource type
3 participants