-
New Feature
-
Resolution: Unresolved
-
Minor
-
None
As a user I want to make sure that Kubernetes Objects created by the Jenkins Kubernetes Plugin don't exist longer than a certain deadline in order make sure that automatic downscaling of k8s node pools can be performed. This avoids unnecessary costs for pods which are stuck in error state.
Even though and issue with pods remaining in error state is tracked at https://issues.jenkins-ci.org/browse/JENKINS-54540 the use of jobs would introduce an additional safety using built-in functions of the Kubernetes scheduler.
The concept of jobs is described at https://kubernetes.io/docs/concepts/workloads/controllers/jobs-run-to-completion/. It's the preferred way of performing tasks that terminate in Kubernetes.