Your controller runs on Kubernetes. A node drain for an upgrade kills the controller pod mid-day. How do you make maintenance safe?
AdvancedScenarioPlatform: plugins, JCasC & Kubernetes agents
Answer
Situation read → Single-replica StatefulSet is disrupted by drains.
What I'd do →
- Add a PodDisruptionBudget with
maxUnavailable: 0so drains block until an operator acts. - Schedule maintenance windows: quiet-down via API, wait for builds, then drain.
- Set a long
terminationGracePeriodSecondsand apreStophook that calls/safeExitif desired. - Put the controller on a dedicated node pool upgraded separately.
Why → The controller is a stateful singleton; it needs explicit handling during cluster operations.
Interview tip → Mention that build pods also need PDB thinking or tolerance to eviction.
More on Platform: plugins, JCasC & Kubernetes agents
You inherit a controller with 230 plugins, half unused, on a version two LTS lines behind. Plan the cleanup and upgrade.AdvancedAn admin changes a cloud setting in the UI, and it reverts after the next controller restart. Developers are confused. What is your policy?BeginnerYou must stand up a new Jenkins controller for a team in under an hour, identical to the existing ones. How?IntermediateBuilds wait 2–3 minutes before starting because new agent pods are slow to schedule. How do you speed up agent startup?AdvancedDevelopers need Docker image builds in Kubernetes agents, but the cluster runs containerd and security forbids privileged pods. What do you choose?AdvancedThe controller needs to provision agents in three Kubernetes clusters in different regions. How do you configure it?Advanced