Skip to content

Commit

Permalink
Make the upgrade one-way
Browse files Browse the repository at this point in the history
  • Loading branch information
aristosvo committed Aug 23, 2023
1 parent 496847e commit 354566f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -867,13 +867,6 @@ func TestAccKubernetesCluster_networkPluginModeUpdate(t *testing.T) {
),
},
data.ImportStep(),
{
Config: r.networkPluginBase(data),
Check: acceptance.ComposeTestCheckFunc(
check.That(data.ResourceName).ExistsInAzure(r),
),
},
data.ImportStep(),
})
}

Expand Down
3 changes: 3 additions & 0 deletions internal/services/containers/kubernetes_cluster_resource.go
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,9 @@ func resourceKubernetesCluster() *pluginsdk.Resource {
}
return nil
},
pluginsdk.ForceNewIfChange("network_profile.0.network_plugin_mode", func(ctx context.Context, _, new, meta interface{}) bool {
return new.(string) != string(managedclusters.NetworkPluginModeOverlay) || new != "Overlay"
}),
),

Timeouts: &pluginsdk.ResourceTimeout{
Expand Down

0 comments on commit 354566f

Please sign in to comment.