Skip to content
This repository has been archived by the owner on Nov 27, 2024. It is now read-only.

Commit

Permalink
GA encrypted_interconnect_router on compute router (#5397) (#358)
Browse files Browse the repository at this point in the history
* GA encrypted_interconnect_router on compute router

* Readd note on encrypted interconnect not being GA

Signed-off-by: Modular Magician <[email protected]>
  • Loading branch information
modular-magician authored Oct 29, 2021
1 parent babad07 commit d7eff9a
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions converters/google/resources/compute_router.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,12 @@ func GetComputeRouterApiObject(d TerraformResourceData, config *Config) (map[str
} else if v, ok := d.GetOkExists("bgp"); ok || !reflect.DeepEqual(v, bgpProp) {
obj["bgp"] = bgpProp
}
encryptedInterconnectRouterProp, err := expandComputeRouterEncryptedInterconnectRouter(d.Get("encrypted_interconnect_router"), d, config)
if err != nil {
return nil, err
} else if v, ok := d.GetOkExists("encrypted_interconnect_router"); !isEmptyValue(reflect.ValueOf(encryptedInterconnectRouterProp)) && (ok || !reflect.DeepEqual(v, encryptedInterconnectRouterProp)) {
obj["encryptedInterconnectRouter"] = encryptedInterconnectRouterProp
}
regionProp, err := expandComputeRouterRegion(d.Get("region"), d, config)
if err != nil {
return nil, err
Expand Down Expand Up @@ -211,6 +217,10 @@ func expandComputeRouterBgpAdvertisedIpRangesDescription(v interface{}, d Terraf
return v, nil
}

func expandComputeRouterEncryptedInterconnectRouter(v interface{}, d TerraformResourceData, config *Config) (interface{}, error) {
return v, nil
}

func expandComputeRouterRegion(v interface{}, d TerraformResourceData, config *Config) (interface{}, error) {
f, err := parseGlobalFieldValue("regions", v.(string), "project", d, config, true)
if err != nil {
Expand Down

0 comments on commit d7eff9a

Please sign in to comment.