beacon-biosignals / K8sClusterManagers.jl

A Julia cluster manager for Kubernetes
Other
31 stars 5 forks source link

Delete cluster test pods when successful #54

Open omus opened 3 years ago

omus commented 3 years ago

Currently the cluster tests do not clean up the jobs/pods they create. This is definitely useful for investigating failures via kubectl but when tests are successful they are just leaving a mess behind. We should setup the tests to automatically delete the resources created by the tests only if they were successful.

omus commented 3 years ago

It should also be mentioned that k8s jobs have a .spec.ttlSecondsAfterFinished to automatically delete themselves after they have completed. However, this feature is only available for jobs.

omus commented 3 years ago

Something else to note: completed/terminated pods are eventually cleaned up due to pod garbage collection but that isn't something we can make use of here