Why LimitRange Is Not Injecting Default Requests and Limits into Running Pods
Scenario
A LimitRange named range-delta is configured in the project-delta namespace with default CPU and memory requests and limits.
A Deployment named web-app is running 3 Pods in the same namespace. However, none of the Pods have CPU or memory requests and limits applied.
Investigate why the LimitRange is not injecting default limits and requests, and fix the issue without modifying the LimitRange configuration
Task
Find and fix the root cause of why LimitRange defaults are not being applied to Pods.
Ensure all Pods of web-app automatically receive the default resource requests and limits from range-delta.
⏳ Wait for about 1 minute for the environment to be fully set up.
⚠️ Do not modify the LimitRange or the Deployment.
Hint
SSH into the control plane node and inspect the kube-apiserver manifest:
/etc/kubernetes/manifests/kube-apiserver.yaml
Look for admission controller flags related to LimitRanger.
If it is disabled, adjust the configuration so that LimitRanger is active again.