How do you limit the number of concurrent agent pods?
BeginnerConceptPlugins, JCasC & Jenkins on Kubernetes
Answer
Set Concurrency Limit on the cloud (containerCapStr in JCasC) and per pod template (instanceCap). Back it with a Kubernetes ResourceQuota on the agent namespace so the cluster enforces limits even if Jenkins misbehaves. Excess builds wait in the Jenkins queue rather than flooding the scheduler with pending pods.
More on Plugins, JCasC & Jenkins on Kubernetes
How do you manage plugins in a reproducible way?IntermediateWhat does `jenkins-plugin-cli` resolve for you, and what flags matter?IntermediateWhy should you keep the number of plugins low?BeginnerWhat is JCasC and how is it loaded?BeginnerWhat are the top-level root elements in a JCasC file?IntermediateHow do you inject secrets into JCasC without committing them?Advanced