Skip to content

Commit

Permalink
add PREMIUM for Global external IP addresses (#9089) (#6456)
Browse files Browse the repository at this point in the history
* add PREMIUM for Global external IP addresses

* exclude when  address_type is INTERNAL

---------


[upstream:18b31019fb163570469572e2547aeee61f347c08]

Signed-off-by: Modular Magician <[email protected]>
  • Loading branch information
modular-magician authored Oct 5, 2023
1 parent 156724a commit 5018c57
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .changelog/9089.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:bug
compute: fixed `google_compute_global_address` can't be created when default_network_tier set to STANDARD
```
Original file line number Diff line number Diff line change
Expand Up @@ -270,6 +270,11 @@ func resourceComputeGlobalAddressCreate(d *schema.ResourceData, meta interface{}
billingProject = bp
}

// Note: Global external IP addresses and internal IP addresses are always Premium Tier.
// An address with type INTERNAL cannot have a network tier
if addressTypeProp != "INTERNAL" {
obj["networkTier"] = "PREMIUM"
}
res, err := transport_tpg.SendRequest(transport_tpg.SendRequestOptions{
Config: config,
Method: "POST",
Expand Down

0 comments on commit 5018c57

Please sign in to comment.