Add note to net-vpn-ha module's README file on how to handle cycle errors when using for_each

This commit is contained in:
Andrea Gandolfi 2022-03-01 07:14:33 +00:00 committed by Julio Castillo
parent ea79b339e9
commit ddc3c4655f
1 changed files with 2 additions and 0 deletions

View File

@ -90,6 +90,8 @@ module "vpn_ha-2" {
# tftest modules=2 resources=18
```
Note: When using the `for_each` Meta-Argument you might experience a Cycle Error due to the multiple `net-vpn-ha` modules referencing each others. To fix this you can create the [google_compute_ha_vpn_gateway](https://registry.terraform.io/providers/hashicorp/google/latest/docs/resources/compute_ha_vpn_gateway) resources separately and reference them in the `net-vpn-ha` module via the `vpn_gateway` and `peer_gcp_gateway` variables.
### GCP to on-prem
```hcl