Skip to content

Commit

Permalink
modify ClusterNodePoolUpdate and modify markdown
Browse files Browse the repository at this point in the history
  • Loading branch information
qiqingzhang committed Apr 24, 2022
1 parent 5065854 commit 2471b6a
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -653,10 +653,7 @@ func resourceKubernetesClusterNodePoolUpdate(d *pluginsdk.ResourceData, meta int
}

if d.HasChange("node_labels") {
nodeLabelsRaw := d.Get("node_labels").(map[string]interface{})
if nodeLabels := utils.ExpandMapStringPtrString(nodeLabelsRaw); len(nodeLabels) > 0 {
props.NodeLabels = nodeLabels
}
props.NodeLabels = utils.ExpandMapStringPtrString(d.Get("node_labels").(map[string]interface{}))
}

// validate the auto-scale fields are both set/unset to prevent a continual diff
Expand Down
2 changes: 1 addition & 1 deletion website/docs/r/kubernetes_cluster.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -329,7 +329,7 @@ A `default_node_pool` block supports the following:

* `node_public_ip_prefix_id` - (Optional) Resource ID for the Public IP Addresses Prefix for the nodes in this Node Pool. `enable_node_public_ip` should be `true`. Changing this forces a new resource to be created.

* `node_labels` - (Optional) A map of Kubernetes labels which should be applied to nodes in the Default Node Pool. Changing this forces a new resource to be created.
* `node_labels` - (Optional) A map of Kubernetes labels which should be applied to nodes in the Default Node Pool.

* `only_critical_addons_enabled` - (Optional) Enabling this option will taint default node pool with `CriticalAddonsOnly=true:NoSchedule` taint. Changing this forces a new resource to be created.

Expand Down
2 changes: 1 addition & 1 deletion website/docs/r/kubernetes_cluster_node_pool.html.markdown
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ The following arguments are supported:

* `mode` - (Optional) Should this Node Pool be used for System or User resources? Possible values are `System` and `User`. Defaults to `User`.

* `node_labels` - (Optional) A map of Kubernetes labels which should be applied to nodes in this Node Pool. Changing this forces a new resource to be created.
* `node_labels` - (Optional) A map of Kubernetes labels which should be applied to nodes in this Node Pool.

* `node_public_ip_prefix_id` - (Optional) Resource ID for the Public IP Addresses Prefix for the nodes in this Node Pool. `enable_node_public_ip` should be `true`. Changing this forces a new resource to be created.

Expand Down

0 comments on commit 2471b6a

Please sign in to comment.