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

Add support for compute network routing mode #838

Merged
merged 2 commits into from
Dec 12, 2017

Conversation

mrparkers
Copy link
Contributor

@mrparkers mrparkers commented Dec 11, 2017

I had a need for this when building a VPC that talks to an on-prem network, and noticed that this provider doesn't have a way to specify the VPC routing mode. The current workaround is to add gcloud compute networks update my-vpc --project my-project --bgp-routing-mode global to local-exec after creating the VPC.

I did a quick search and found that this was asked for in #629.

Docs:

Tests:

TF_ACC=1 go test $(go list ./... |grep -v 'vendor') -v -run=TestAccComputeNetwork.*routing_mode -timeout 120m
?   	github.com/terraform-providers/terraform-provider-google	[no test files]
=== RUN   TestAccComputeNetwork_routing_mode
=== RUN   TestAccComputeNetwork_default_routing_mode
--- PASS: TestAccComputeNetwork_routing_mode (336.44s)
--- PASS: TestAccComputeNetwork_default_routing_mode (336.46s)
PASS
ok  	github.com/terraform-providers/terraform-provider-google/google	336.487s
testing: warning: no tests to run
PASS
ok  	github.com/terraform-providers/terraform-provider-google/scripts	0.017s [no tests to run]

Side note: It is possible to change the routing mode after creating the VPC, but this resource doesn't have an UpdateFunc and I didn't want to go through the work of supporting it in this PR. However, if you'd like me to add it before this gets merged, I can do that.

@terraform-ctc
Copy link

Great work! We have the same use case, vpc w/ on-prem networks, so would love to see this get merged asap.

@rosbo rosbo self-requested a review December 12, 2017 18:29
Copy link
Contributor

@rosbo rosbo left a comment

Choose a reason for hiding this comment

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

Thank you Michael for adding this feature! :)

I filed a separate issue (#846) for adding update support for this field.

@rosbo rosbo merged commit 606103a into hashicorp:master Dec 12, 2017
@mrparkers mrparkers deleted the compute-network-routing-mode branch December 12, 2017 21:30
@mrparkers
Copy link
Contributor Author

#847 you mean? 😉

@rosbo
Copy link
Contributor

rosbo commented Dec 12, 2017

Ooopsi. Yes :)

chrisst pushed a commit to chrisst/terraform-provider-google that referenced this pull request Nov 9, 2018
* Add ability to specify compute network routing mode
* Update docs
modular-magician added a commit to modular-magician/terraform-provider-google that referenced this pull request Sep 27, 2019
Signed-off-by: Modular Magician <magic-modules@google.com>
@ghost
Copy link

ghost commented Mar 30, 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 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 👉 hashibot-feedback@hashicorp.com. Thanks!

@ghost ghost locked and limited conversation to collaborators Mar 30, 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.

3 participants