diff --git a/.changelog/3527.txt b/.changelog/3527.txt new file mode 100644 index 0000000000..f0d32c23d2 --- /dev/null +++ b/.changelog/3527.txt @@ -0,0 +1,3 @@ +```release-note:enhancement +datasource/tencentcloud_teo_origin_acl: update doc +``` diff --git a/tencentcloud/services/teo/data_source_tc_teo_origin_acl.go b/tencentcloud/services/teo/data_source_tc_teo_origin_acl.go index 28be56dae4..a90d10afe1 100644 --- a/tencentcloud/services/teo/data_source_tc_teo_origin_acl.go +++ b/tencentcloud/services/teo/data_source_tc_teo_origin_acl.go @@ -29,7 +29,7 @@ func DataSourceTencentCloudTeoOriginAcl() *schema.Resource { Schema: map[string]*schema.Schema{ "l7_hosts": { Type: schema.TypeSet, - Optional: true, + Computed: true, Description: "The list of L7 accelerated domains that enable the origin ACLs. This field is empty when origin protection is not enabled.", Elem: &schema.Schema{ Type: schema.TypeString, @@ -37,7 +37,7 @@ func DataSourceTencentCloudTeoOriginAcl() *schema.Resource { }, "l4_proxy_ids": { Type: schema.TypeSet, - Optional: true, + Computed: true, Description: "The list of L4 proxy instances that enable the origin ACLs. This field is empty when origin protection is not enabled.", Elem: &schema.Schema{ Type: schema.TypeString, @@ -45,21 +45,19 @@ func DataSourceTencentCloudTeoOriginAcl() *schema.Resource { }, "current_origin_acl": { Type: schema.TypeList, - Optional: true, - MaxItems: 1, + Computed: true, Description: "Currently effective origin ACLs. This field is empty when origin protection is not enabled.\nNote: This field may return null, which indicates a failure to obtain a valid value.", Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "entire_addresses": { Type: schema.TypeList, - Optional: true, - MaxItems: 1, + Computed: true, Description: "IP range details.\nNote: This field may return null, which indicates a failure to obtain a valid value.", Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "i_pv4": { Type: schema.TypeSet, - Optional: true, + Computed: true, Description: "IPv4 subnet.", Elem: &schema.Schema{ Type: schema.TypeString, @@ -67,7 +65,7 @@ func DataSourceTencentCloudTeoOriginAcl() *schema.Resource { }, "i_pv6": { Type: schema.TypeSet, - Optional: true, + Computed: true, Description: "IPv6 subnet.", Elem: &schema.Schema{ Type: schema.TypeString, @@ -78,17 +76,17 @@ func DataSourceTencentCloudTeoOriginAcl() *schema.Resource { }, "version": { Type: schema.TypeString, - Optional: true, + Computed: true, Description: "Version number.\nNote: This field may return null, which indicates a failure to obtain a valid value.", }, "active_time": { Type: schema.TypeString, - Optional: true, + Computed: true, Description: "Version effective time in UTC+8, following the date and time format of the ISO 8601 standard.\nNote: This field may return null, which indicates a failure to obtain a valid value.", }, "is_planed": { Type: schema.TypeString, - Optional: true, + Computed: true, Description: "This parameter is used to record whether \"I've upgraded to the lastest version\" is completed before the origin ACLs version is effective. valid values:.\n- true: specifies that the version is effective and the update to the latest version is confirmed.\n- false: when the version takes effect, the confirmation of updating to the latest origin ACLs are not completed. The IP range is forcibly updated to the latest version in the backend. When this parameter returns false, please confirm in time whether your origin server firewall configuration has been updated to the latest version to avoid origin-pull failure.\nNote: This field may return null, which indicates a failure to obtain a valid value.", }, }, @@ -96,31 +94,29 @@ func DataSourceTencentCloudTeoOriginAcl() *schema.Resource { }, "next_origin_acl": { Type: schema.TypeList, - Optional: true, - MaxItems: 1, + Computed: true, Description: "When the origin ACLs are updated, this field will be returned with the next version's origin IP range to take effect, including a comparison with the current origin IP range. This field is empty if not updated or origin protection is not enabled.\nNote: This field may return null, which indicates a failure to obtain a valid value.", Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "version": { Type: schema.TypeString, - Optional: true, + Computed: true, Description: "Version number.", }, "planned_active_time": { Type: schema.TypeString, - Optional: true, + Computed: true, Description: "Version effective time, which adopts UTC+8 and follows the date and time format of the ISO 8601 standard.", }, "entire_addresses": { Type: schema.TypeList, - Optional: true, - MaxItems: 1, + Computed: true, Description: "IP range details.", Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "i_pv4": { Type: schema.TypeSet, - Optional: true, + Computed: true, Description: "IPv4 subnet.", Elem: &schema.Schema{ Type: schema.TypeString, @@ -128,7 +124,7 @@ func DataSourceTencentCloudTeoOriginAcl() *schema.Resource { }, "i_pv6": { Type: schema.TypeSet, - Optional: true, + Computed: true, Description: "IPv6 subnet.", Elem: &schema.Schema{ Type: schema.TypeString, @@ -139,14 +135,13 @@ func DataSourceTencentCloudTeoOriginAcl() *schema.Resource { }, "added_addresses": { Type: schema.TypeList, - Optional: true, - MaxItems: 1, + Computed: true, Description: "The latest origin IP range newly-added compared with the origin IP range in CurrentOrginACL.", Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "i_pv4": { Type: schema.TypeSet, - Optional: true, + Computed: true, Description: "IPv4 subnet.", Elem: &schema.Schema{ Type: schema.TypeString, @@ -154,7 +149,7 @@ func DataSourceTencentCloudTeoOriginAcl() *schema.Resource { }, "i_pv6": { Type: schema.TypeSet, - Optional: true, + Computed: true, Description: "IPv6 subnet.", Elem: &schema.Schema{ Type: schema.TypeString, @@ -165,14 +160,13 @@ func DataSourceTencentCloudTeoOriginAcl() *schema.Resource { }, "removed_addresses": { Type: schema.TypeList, - Optional: true, - MaxItems: 1, + Computed: true, Description: "The latest origin IP range deleted compared with the origin IP range in CurrentOrginACL.", Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "i_pv4": { Type: schema.TypeSet, - Optional: true, + Computed: true, Description: "IPv4 subnet.", Elem: &schema.Schema{ Type: schema.TypeString, @@ -180,7 +174,7 @@ func DataSourceTencentCloudTeoOriginAcl() *schema.Resource { }, "i_pv6": { Type: schema.TypeSet, - Optional: true, + Computed: true, Description: "IPv6 subnet.", Elem: &schema.Schema{ Type: schema.TypeString, @@ -191,14 +185,13 @@ func DataSourceTencentCloudTeoOriginAcl() *schema.Resource { }, "no_change_addresses": { Type: schema.TypeList, - Optional: true, - MaxItems: 1, + Computed: true, Description: "The latest origin IP range is unchanged compared with the origin IP range in CurrentOrginACL.", Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ "i_pv4": { Type: schema.TypeSet, - Optional: true, + Computed: true, Description: "IPv4 subnet.", Elem: &schema.Schema{ Type: schema.TypeString, @@ -206,7 +199,7 @@ func DataSourceTencentCloudTeoOriginAcl() *schema.Resource { }, "i_pv6": { Type: schema.TypeSet, - Optional: true, + Computed: true, Description: "IPv6 subnet.", Elem: &schema.Schema{ Type: schema.TypeString, @@ -220,7 +213,7 @@ func DataSourceTencentCloudTeoOriginAcl() *schema.Resource { }, "status": { Type: schema.TypeString, - Optional: true, + Computed: true, Description: "Origin protection status. Vaild values:\n- online: in effect;\n- offline: disabled;\n- updating: configuration deployment in progress.", }, }, diff --git a/website/docs/d/teo_origin_acl.html.markdown b/website/docs/d/teo_origin_acl.html.markdown index 3265472f2a..833220a8a8 100644 --- a/website/docs/d/teo_origin_acl.html.markdown +++ b/website/docs/d/teo_origin_acl.html.markdown @@ -33,5 +33,41 @@ The following arguments are supported: In addition to all arguments above, the following attributes are exported: * `origin_acl_info` - Describes the binding relationship between the l7 acceleration domain/l4 proxy instance and the origin server IP range. + * `current_origin_acl` - Currently effective origin ACLs. This field is empty when origin protection is not enabled. +Note: This field may return null, which indicates a failure to obtain a valid value. + * `active_time` - Version effective time in UTC+8, following the date and time format of the ISO 8601 standard. +Note: This field may return null, which indicates a failure to obtain a valid value. + * `entire_addresses` - IP range details. +Note: This field may return null, which indicates a failure to obtain a valid value. + * `i_pv4` - IPv4 subnet. + * `i_pv6` - IPv6 subnet. + * `is_planed` - This parameter is used to record whether "I've upgraded to the lastest version" is completed before the origin ACLs version is effective. valid values:. +- true: specifies that the version is effective and the update to the latest version is confirmed. +- false: when the version takes effect, the confirmation of updating to the latest origin ACLs are not completed. The IP range is forcibly updated to the latest version in the backend. When this parameter returns false, please confirm in time whether your origin server firewall configuration has been updated to the latest version to avoid origin-pull failure. +Note: This field may return null, which indicates a failure to obtain a valid value. + * `version` - Version number. +Note: This field may return null, which indicates a failure to obtain a valid value. + * `l4_proxy_ids` - The list of L4 proxy instances that enable the origin ACLs. This field is empty when origin protection is not enabled. + * `l7_hosts` - The list of L7 accelerated domains that enable the origin ACLs. This field is empty when origin protection is not enabled. + * `next_origin_acl` - When the origin ACLs are updated, this field will be returned with the next version's origin IP range to take effect, including a comparison with the current origin IP range. This field is empty if not updated or origin protection is not enabled. +Note: This field may return null, which indicates a failure to obtain a valid value. + * `added_addresses` - The latest origin IP range newly-added compared with the origin IP range in CurrentOrginACL. + * `i_pv4` - IPv4 subnet. + * `i_pv6` - IPv6 subnet. + * `entire_addresses` - IP range details. + * `i_pv4` - IPv4 subnet. + * `i_pv6` - IPv6 subnet. + * `no_change_addresses` - The latest origin IP range is unchanged compared with the origin IP range in CurrentOrginACL. + * `i_pv4` - IPv4 subnet. + * `i_pv6` - IPv6 subnet. + * `planned_active_time` - Version effective time, which adopts UTC+8 and follows the date and time format of the ISO 8601 standard. + * `removed_addresses` - The latest origin IP range deleted compared with the origin IP range in CurrentOrginACL. + * `i_pv4` - IPv4 subnet. + * `i_pv6` - IPv6 subnet. + * `version` - Version number. + * `status` - Origin protection status. Vaild values: +- online: in effect; +- offline: disabled; +- updating: configuration deployment in progress.