@@ -36,17 +36,55 @@ func TestAccTencentCloudVpnGatewaySslClientCertResource_basic(t *testing.T) {
3636
3737const testAccVpnGatewaySslClientCert = `
3838
39+ resource "tencentcloud_vpn_ssl_server" "server" {
40+ local_address = [
41+ "172.16.0.0/17",
42+ ]
43+ remote_address = "173.16.1.0/24"
44+ ssl_vpn_server_name = "tf-vpn-ssl-server"
45+ vpn_gateway_id = "vpngw-mll9np1x"
46+ ssl_vpn_protocol = "UDP"
47+ ssl_vpn_port = 1194
48+ integrity_algorithm = "MD5"
49+ encrypt_algorithm = "AES-128-CBC"
50+ compress = false
51+ }
52+
53+ resource "tencentcloud_vpn_ssl_client" "client" {
54+ ssl_vpn_server_id = tencentcloud_vpn_ssl_server.server.id
55+ ssl_vpn_client_name = "tf-vpn-ssl-client"
56+ }
57+
3958resource "tencentcloud_vpn_gateway_ssl_client_cert" "vpn_gateway_ssl_client_cert" {
40- ssl_vpn_client_id = "vpnc-52f5lnd5"
59+ ssl_vpn_client_id = tencentcloud_vpn_ssl_client.client.id
4160 switch = "off"
4261}
4362
4463`
4564
4665const testAccVpnGatewaySslClientCertUpdate = `
4766
67+ resource "tencentcloud_vpn_ssl_server" "server" {
68+ local_address = [
69+ "172.16.0.0/17",
70+ ]
71+ remote_address = "173.16.1.0/24"
72+ ssl_vpn_server_name = "tf-vpn-ssl-server"
73+ vpn_gateway_id = "vpngw-mll9np1x"
74+ ssl_vpn_protocol = "UDP"
75+ ssl_vpn_port = 1194
76+ integrity_algorithm = "MD5"
77+ encrypt_algorithm = "AES-128-CBC"
78+ compress = false
79+ }
80+
81+ resource "tencentcloud_vpn_ssl_client" "client" {
82+ ssl_vpn_server_id = tencentcloud_vpn_ssl_server.server.id
83+ ssl_vpn_client_name = "tf-vpn-ssl-client"
84+ }
85+
4886resource "tencentcloud_vpn_gateway_ssl_client_cert" "vpn_gateway_ssl_client_cert" {
49- ssl_vpn_client_id = "vpnc-52f5lnd5"
87+ ssl_vpn_client_id = tencentcloud_vpn_ssl_client.client.id
5088 switch = "on"
5189}
5290
0 commit comments