Mark pods with restartable init containers as UnschedulableAndUnresolvable

This marks the pods with restartable init containers as
`UnschedulableAndUnresolvable` if the feature gate is disabled to avoid
the inconsistency in resource calculation between the scheduler and the
older kubelet.
This commit is contained in:
Gunju Kim
2023-05-16 23:41:53 +09:00
parent 0a98707912
commit 7286d122fb
4 changed files with 101 additions and 0 deletions

View File

@@ -56,6 +56,7 @@ func NewInTreeRegistry() runtime.Registry {
EnablePodSchedulingReadiness: feature.DefaultFeatureGate.Enabled(features.PodSchedulingReadiness),
EnablePodDisruptionConditions: feature.DefaultFeatureGate.Enabled(features.PodDisruptionConditions),
EnableInPlacePodVerticalScaling: feature.DefaultFeatureGate.Enabled(features.InPlacePodVerticalScaling),
EnableSidecarContainers: feature.DefaultFeatureGate.Enabled(features.SidecarContainers),
}
registry := runtime.Registry{