Skip to content

feat(cfw): [119799613] support sg rule #2886

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Oct 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .changelog/2886.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:new-resource
tencentcloud_sg_rule
```
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ require (
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/cdn v1.0.1010
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/cdwch v1.0.843
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/cfs v1.0.627
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/cfw v1.0.841
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/cfw v1.0.1018
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/chdfs v1.0.600
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/ciam v1.0.695
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/ckafka v1.0.748
Expand Down
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -852,6 +852,8 @@ github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/cfs v1.0.627 h1:nChNdoC
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/cfs v1.0.627/go.mod h1:lr3IyWgJk4rLWr0vVd8J1Tfs5O+wNcwSZ9ciMhGUrlI=
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/cfw v1.0.841 h1:1GWCoGe7puNJxAtLqV1CqHuZ48zMEkONJc5WEyDNHqk=
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/cfw v1.0.841/go.mod h1:X82Do5gZwZf42fx9uE0DdQjWn0ALF21vhvyITzIhuG8=
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/cfw v1.0.1018 h1:t9pWssFNmbTerWeZAASeJyMxj7V+Xfb6VnPPMHDpkDU=
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/cfw v1.0.1018/go.mod h1:/o55E2/cnFVNlRWkpqgn+UHN3sK6AAIYDZOsxPEvdRM=
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/chdfs v1.0.600 h1:qSpp4rEgAzfXhi1rPxes+AJp2mwnsyRGPY/Km1FuYGs=
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/chdfs v1.0.600/go.mod h1:xud1dQ7Rc23yC5kS00TYRrvZ/A+94EOkwquaI6xGVac=
github.com/tencentcloud/tencentcloud-sdk-go/tencentcloud/ciam v1.0.695 h1:FGwsF1/PgY+M92bEC+0NH4tJkI8i0qjrLbZWVjLXOAY=
Expand Down
14 changes: 14 additions & 0 deletions tencentcloud/connectivity/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,7 @@ type TencentCloudClient struct {
teov20220901Conn *teo.Client
sslv20191205Conn *sslCertificate.Client
postgresv20170312Conn *postgre.Client
cfwv20190904Conn *cfw.Client
}

// NewClientProfile returns a new ClientProfile
Expand Down Expand Up @@ -1872,3 +1873,16 @@ func (me *TencentCloudClient) UsePostgresV20170312Client() *postgre.Client {

return me.postgresv20170312Conn
}

// UseCfwV20190904Client return CFW client for service
func (me *TencentCloudClient) UseCfwV20190904Client() *cfw.Client {
if me.cfwv20190904Conn != nil {
return me.cfwv20190904Conn
}
cpf := me.NewClientProfile(300)
cpf.Language = "zh-CN"
me.cfwv20190904Conn, _ = cfw.NewClient(me.Credential, me.Region, cpf)
me.cfwv20190904Conn.WithHttpTransport(&LogRoundTripper{})

return me.cfwv20190904Conn
}
1 change: 1 addition & 0 deletions tencentcloud/provider.go
Original file line number Diff line number Diff line change
Expand Up @@ -2094,6 +2094,7 @@ func Provider() *schema.Provider {
"tencentcloud_cfw_nat_firewall_switch": cfw.ResourceTencentCloudCfwNatFirewallSwitch(),
"tencentcloud_cfw_vpc_firewall_switch": cfw.ResourceTencentCloudCfwVpcFirewallSwitch(),
"tencentcloud_cfw_edge_firewall_switch": cfw.ResourceTencentCloudCfwEdgeFirewallSwitch(),
"tencentcloud_sg_rule": cfw.ResourceTencentCloudSgRule(),
"tencentcloud_dasb_acl": bh.ResourceTencentCloudDasbAcl(),
"tencentcloud_dasb_cmd_template": bh.ResourceTencentCloudDasbCmdTemplate(),
"tencentcloud_dasb_device_group": bh.ResourceTencentCloudDasbDeviceGroup(),
Expand Down
1 change: 1 addition & 0 deletions tencentcloud/provider.md
Original file line number Diff line number Diff line change
Expand Up @@ -2135,6 +2135,7 @@ Cloud Firewall(CFW)
tencentcloud_cfw_nat_firewall_switch
tencentcloud_cfw_vpc_firewall_switch
tencentcloud_cfw_edge_firewall_switch
tencentcloud_sg_rule

Bastion Host(BH)
Resource
Expand Down
Loading
Loading