Skip to content

Commit fd22afd

Browse files
authored
fix(clb): [122360685] tencentcloud_clb_listener_rule support health_source_ip_type param (#3208)
* add * add
1 parent 223b7d0 commit fd22afd

File tree

3 files changed

+14
-0
lines changed

3 files changed

+14
-0
lines changed

.changelog/3208.txt

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
```release-note:enhancement
2+
resource/tencentcloud_clb_listener_rule: support `health_source_ip_type` param
3+
```

tencentcloud/services/clb/resource_tc_clb_listener_rule.go

+10
Original file line numberDiff line numberDiff line change
@@ -133,6 +133,13 @@ func ResourceTencentCloudClbListenerRule() *schema.Resource {
133133
ValidateFunc: tccommon.ValidateAllowedStringValue(CLB_HTTP_METHOD),
134134
Description: "Methods of health check. NOTES: Only supports listeners of `HTTP` and `HTTPS` protocol. The default is `HEAD`, the available value are `HEAD` and `GET`.",
135135
},
136+
"health_source_ip_type": {
137+
Type: schema.TypeInt,
138+
Optional: true,
139+
Computed: true,
140+
ValidateFunc: tccommon.ValidateAllowedIntValue([]int{0, 1}),
141+
Description: "Specifies the type of health check source IP. `0` (default): CLB VIP. `1`: 100.64 IP range.",
142+
},
136143
"certificate_ssl_mode": {
137144
Type: schema.TypeString,
138145
Optional: true,
@@ -613,6 +620,9 @@ func resourceTencentCloudClbListenerRuleRead(d *schema.ResourceData, meta interf
613620
}
614621
_ = d.Set("health_check_type", instance.HealthCheck.CheckType)
615622
_ = d.Set("health_check_time_out", instance.HealthCheck.TimeOut)
623+
if instance.HealthCheck.SourceIpType != nil {
624+
_ = d.Set("health_source_ip_type", instance.HealthCheck.SourceIpType)
625+
}
616626
}
617627

618628
if instance.Certificate != nil {

website/docs/r/clb_listener_rule.html.markdown

+1
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,7 @@ The following arguments are supported:
9393
* `health_check_time_out` - (Optional, Int) Time out of health check. The value range is [2-60](SEC).
9494
* `health_check_type` - (Optional, String) Type of health check. Valid value is `CUSTOM`, `PING`, `TCP`, `HTTP`, `HTTPS`, `GRPC`, `GRPCS`.
9595
* `health_check_unhealth_num` - (Optional, Int) Unhealthy threshold of health check, and the default is `3`. If the unhealthy result is returned 3 consecutive times, indicates that the forwarding is abnormal. The value range is [2-10]. NOTES: TCP/UDP/TCP_SSL listener allows direct configuration, HTTP/HTTPS listener needs to be configured in `tencentcloud_clb_listener_rule`.
96+
* `health_source_ip_type` - (Optional, Int) Specifies the type of health check source IP. `0` (default): CLB VIP. `1`: 100.64 IP range.
9697
* `http2_switch` - (Optional, Bool) Indicate to apply HTTP2.0 protocol or not.
9798
* `multi_cert_info` - (Optional, List) Certificate information. You can specify multiple server-side certificates with different algorithm types. This parameter is only applicable to HTTPS listeners with the SNI feature not enabled. Certificate and MultiCertInfo cannot be specified at the same time.
9899
* `oauth` - (Optional, List) OAuth configuration information.

0 commit comments

Comments
 (0)