Skip to content

Commit

Permalink
Adapt to the removal of the PersistentVolumeLabel admission plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
ialidzhikov committed Sep 25, 2024
1 parent 0e0ce8a commit 945bbd4
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions pkg/webhook/controlplane/ensurer.go
Original file line number Diff line number Diff line change
Expand Up @@ -220,10 +220,12 @@ func ensureKubeAPIServerCommandLineArgs(c *corev1.Container, k8sVersion *semver.

c.Command = extensionswebhook.EnsureNoStringWithPrefix(c.Command, "--cloud-provider=")
c.Command = extensionswebhook.EnsureNoStringWithPrefix(c.Command, "--cloud-config=")
c.Command = extensionswebhook.EnsureNoStringWithPrefixContains(c.Command, "--enable-admission-plugins=",
"PersistentVolumeLabel", ",")
c.Command = extensionswebhook.EnsureStringWithPrefixContains(c.Command, "--disable-admission-plugins=",
"PersistentVolumeLabel", ",")
if constraintK8sLess131.Check(k8sVersion) {
c.Command = extensionswebhook.EnsureNoStringWithPrefixContains(c.Command, "--enable-admission-plugins=",
"PersistentVolumeLabel", ",")
c.Command = extensionswebhook.EnsureStringWithPrefixContains(c.Command, "--disable-admission-plugins=",
"PersistentVolumeLabel", ",")
}
}

func ensureKubeControllerManagerCommandLineArgs(c *corev1.Container, k8sVersion *semver.Version) {
Expand Down

0 comments on commit 945bbd4

Please sign in to comment.