diff --git a/internal/services/containers/kubernetes_cluster_node_pool_resource.go b/internal/services/containers/kubernetes_cluster_node_pool_resource.go index 6ef5c4fba494..c8d90a1bbe22 100644 --- a/internal/services/containers/kubernetes_cluster_node_pool_resource.go +++ b/internal/services/containers/kubernetes_cluster_node_pool_resource.go @@ -208,10 +208,15 @@ func resourceKubernetesClusterNodePoolSchema() map[string]*pluginsdk.Schema { }, "node_public_ip_prefix_id": { - Type: pluginsdk.TypeString, - Optional: true, - ForceNew: true, - RequiredWith: []string{"enable_node_public_ip"}, + Type: pluginsdk.TypeString, + Optional: true, + ForceNew: true, + RequiredWith: func() []string { + if !features.FourPointOhBeta() { + return []string{"enable_node_public_ip"} + } + return []string{"node_public_ip_enabled"} + }(), }, // Node Taints control the behaviour of the Node Pool, as such they should not be computed and diff --git a/internal/services/containers/kubernetes_nodepool.go b/internal/services/containers/kubernetes_nodepool.go index a2de98849644..de32e6ee4980 100644 --- a/internal/services/containers/kubernetes_nodepool.go +++ b/internal/services/containers/kubernetes_nodepool.go @@ -166,7 +166,12 @@ func SchemaDefaultNodePool() *pluginsdk.Schema { Optional: true, ForceNew: true, ValidateFunc: networkValidate.PublicIpPrefixID, - RequiredWith: []string{"default_node_pool.0.enable_node_public_ip"}, + RequiredWith: func() []string { + if !features.FourPointOhBeta() { + return []string{"default_node_pool.0.enable_node_public_ip"} + } + return []string{"default_node_pool.0.node_public_ip_enabled"} + }(), }, "node_taints": { diff --git a/internal/services/network/subnet_resource.go b/internal/services/network/subnet_resource.go index 38d3688b0883..eacc94a744b3 100644 --- a/internal/services/network/subnet_resource.go +++ b/internal/services/network/subnet_resource.go @@ -212,7 +212,7 @@ func resourceSubnet() *pluginsdk.Resource { return !features.FourPointOh() }(), ConflictsWith: func() []string { - if !features.FourPointOh() { + if !features.FourPointOhBeta() { return []string{"enforce_private_link_endpoint_network_policies"} } return []string{}