@@ -33,25 +33,23 @@ func resourceTencentCloudKubernetesClusterMasterAttachmentCreatePostFillRequest0
33
33
}
34
34
35
35
if v , ok := d .GetOkExists ("enhanced_security_service" ); ok {
36
- enhancedService .SecurityService = & tkev20180525.RunSecurityServiceEnabled {
37
- Enabled : helper .Bool (v .(bool )),
38
- }
36
+ enhancedService .SecurityService = & tkev20180525.RunSecurityServiceEnabled {Enabled : helper .Bool (v .(bool ))}
37
+ existedInstancesPara .EnhancedService = & enhancedService
39
38
}
40
39
41
40
if v , ok := d .GetOkExists ("enhanced_monitor_service" ); ok {
42
- enhancedService .MonitorService = & tkev20180525.RunMonitorServiceEnabled {
43
- Enabled : helper .Bool (v .(bool )),
44
- }
41
+ enhancedService .MonitorService = & tkev20180525.RunMonitorServiceEnabled {Enabled : helper .Bool (v .(bool ))}
42
+ existedInstancesPara .EnhancedService = & enhancedService
45
43
}
46
44
47
45
if v , ok := d .GetOkExists ("enhanced_automation_service" ); ok {
48
- enhancedService .AutomationService = & tkev20180525.RunAutomationServiceEnabled {
49
- Enabled : helper .Bool (v .(bool )),
50
- }
46
+ enhancedService .AutomationService = & tkev20180525.RunAutomationServiceEnabled {Enabled : helper .Bool (v .(bool ))}
47
+ existedInstancesPara .EnhancedService = & enhancedService
51
48
}
52
49
53
50
if v , ok := d .GetOk ("password" ); ok {
54
51
loginSettings .Password = helper .String (v .(string ))
52
+ existedInstancesPara .LoginSettings = & loginSettings
55
53
}
56
54
57
55
if v , ok := d .GetOk ("key_ids" ); ok && len (v .([]interface {})) > 0 {
@@ -61,6 +59,8 @@ func resourceTencentCloudKubernetesClusterMasterAttachmentCreatePostFillRequest0
61
59
keyId := keyIds [i ].(string )
62
60
loginSettings .KeyIds = append (loginSettings .KeyIds , & keyId )
63
61
}
62
+
63
+ existedInstancesPara .LoginSettings = & loginSettings
64
64
}
65
65
66
66
if v , ok := d .GetOk ("security_group_ids" ); ok && len (v .([]interface {})) > 0 {
@@ -309,7 +309,7 @@ func resourceTencentCloudKubernetesClusterMasterAttachmentCreatePostHandleRespon
309
309
}
310
310
311
311
if * resp .InstanceSet [0 ].InstanceState != "running" {
312
- return resource .RetryableError (fmt .Errorf ("tke master node cvm instance %s in tke status is %s, retry..." , instanceId , resp .InstanceSet [0 ].InstanceState ))
312
+ return resource .RetryableError (fmt .Errorf ("tke master node cvm instance %s in tke status is %s, retry..." , instanceId , * resp .InstanceSet [0 ].InstanceState ))
313
313
}
314
314
315
315
return nil
0 commit comments