Skip to content

Commit 58c0d9c

Browse files
committed
adjust unschedulable
1 parent 6f54d22 commit 58c0d9c

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

tencentcloud/services/tke/resource_tc_kubernetes_cluster_attachment_extension.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -48,11 +48,6 @@ func resourceTencentCloudKubernetesClusterAttachmentCreatePostFillRequest0(ctx c
4848
req.InstanceAdvancedSettings = &tke.InstanceAdvancedSettings{}
4949
req.InstanceAdvancedSettings.Labels = GetTkeLabels(d, "labels")
5050

51-
// only this unschedulable is valid, the is_schedule of worker_config and worker_config_overrides was deprecated.
52-
if v, ok := d.GetOkExists("unschedulable"); ok {
53-
req.InstanceAdvancedSettings.Unschedulable = helper.IntInt64(v.(int))
54-
}
55-
5651
if dMap, ok := helper.InterfacesHeadMap(d, "worker_config"); ok {
5752
completeInstanceAdvancedSettings(dMap, req.InstanceAdvancedSettings)
5853
}
@@ -63,6 +58,11 @@ func resourceTencentCloudKubernetesClusterAttachmentCreatePostFillRequest0(ctx c
6358
}
6459
}
6560

61+
// only this unschedulable is valid, the is_schedule of worker_config and worker_config_overrides was deprecated.
62+
if v, ok := d.GetOkExists("unschedulable"); ok {
63+
req.InstanceAdvancedSettings.Unschedulable = helper.IntInt64(v.(int))
64+
}
65+
6666
// 检查是否已经绑定
6767
if hasAttached, err := nodeHasAttachedToCluster(ctx, instanceId, *req.ClusterId); err != nil {
6868
return err

0 commit comments

Comments
 (0)