Skip to content

Commit

Permalink
Merge pull request #112 from volcengine/feat/clb_bandwidth
Browse files Browse the repository at this point in the history
Feat/clb bandwidth
  • Loading branch information
xuyaming0800 authored Aug 10, 2023
2 parents 613351d + e0820e9 commit 406307c
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 13 deletions.
2 changes: 1 addition & 1 deletion common/common_volcengine_version.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ package common

const (
TerraformProviderName = "terraform-provider-volcengine"
TerraformProviderVersion = "0.0.94"
TerraformProviderVersion = "0.0.95"
)
11 changes: 6 additions & 5 deletions volcengine/clb/clb/resource_volcengine_clb.go
Original file line number Diff line number Diff line change
Expand Up @@ -150,11 +150,12 @@ func ResourceVolcengineClb() *schema.Resource {
"When the LoadBalancerBillingType changes from `PostPaid` to `PrePaid`, please manually modify the value of this field to `PrePaid` simultaneously.",
},
"bandwidth": {
Type: schema.TypeInt,
Optional: true,
Computed: true,
ValidateFunc: validation.IntBetween(1, 500),
Description: "The peek bandwidth of the EIP which automatically assigned to CLB. The value range in 1~500 for PostPaidByBandwidth, and 1~200 for PostPaidByTraffic.",
Type: schema.TypeInt,
Optional: true,
Computed: true,
//ValidateFunc: validation.IntBetween(1, 500),
//Description: "The peek bandwidth of the EIP which automatically assigned to CLB. The value range in 1~500 for PostPaidByBandwidth, and 1~200 for PostPaidByTraffic.",
Description: "The peek bandwidth of the EIP which automatically assigned to CLB.",
},
},
},
Expand Down
11 changes: 6 additions & 5 deletions volcengine/eip/eip_address/resource_volcengine_eip_address.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,11 +87,12 @@ func ResourceVolcengineEipAddress() *schema.Resource {
"This field is only effective when creating a PrePaid Eip or changing the billing_type from PostPaid to PrePaid.",
},
"bandwidth": {
Type: schema.TypeInt,
Optional: true,
Computed: true,
ValidateFunc: validation.IntBetween(1, 500),
Description: "The peek bandwidth of the EIP, the value range in 1~500 for PostPaidByBandwidth, and 1~200 for PostPaidByTraffic.",
Type: schema.TypeInt,
Optional: true,
Computed: true,
//ValidateFunc: validation.IntBetween(1, 500),
//Description: "The peek bandwidth of the EIP, the value range in 1~500 for PostPaidByBandwidth, and 1~200 for PostPaidByTraffic.",
Description: "The peek bandwidth of the EIP.",
},
"isp": {
Type: schema.TypeString,
Expand Down
2 changes: 1 addition & 1 deletion website/docs/r/clb.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ The `eip_billing_config` object supports the following:

* `eip_billing_type` - (Required, ForceNew) The billing type of the EIP which automatically assigned to CLB. And optional choice contains `PostPaidByBandwidth` or `PostPaidByTraffic` or `PrePaid`.When creating a `PrePaid` public CLB, this field must be specified as `PrePaid` simultaneously.When the LoadBalancerBillingType changes from `PostPaid` to `PrePaid`, please manually modify the value of this field to `PrePaid` simultaneously.
* `isp` - (Required, ForceNew) The ISP of the EIP which automatically associated to CLB, the value can be `BGP`.
* `bandwidth` - (Optional) The peek bandwidth of the EIP which automatically assigned to CLB. The value range in 1~500 for PostPaidByBandwidth, and 1~200 for PostPaidByTraffic.
* `bandwidth` - (Optional) The peek bandwidth of the EIP which automatically assigned to CLB.

The `tags` object supports the following:

Expand Down
2 changes: 1 addition & 1 deletion website/docs/r/eip_address.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ resource "volcengine_eip_address" "foo" {
## Argument Reference
The following arguments are supported:
* `billing_type` - (Required) The billing type of the EIP Address. And optional choice contains `PostPaidByBandwidth` or `PostPaidByTraffic` or `PrePaid`.
* `bandwidth` - (Optional) The peek bandwidth of the EIP, the value range in 1~500 for PostPaidByBandwidth, and 1~200 for PostPaidByTraffic.
* `bandwidth` - (Optional) The peek bandwidth of the EIP.
* `description` - (Optional) The description of the EIP.
* `isp` - (Optional, ForceNew) The ISP of the EIP, the value can be `BGP` or `ChinaMobile` or `ChinaUnicom` or `ChinaTelecom` or `SingleLine_BGP` or `Static_BGP`.
* `name` - (Optional) The name of the EIP Address.
Expand Down

0 comments on commit 406307c

Please sign in to comment.