Deploying to cluster
kubectl apply -f example/operator.yaml
kubectl apply -f example/cr.yaml
Want to change how often to poll?
- By default this operator will poll for namespaces every 30 seconds, but can be changed.
How the operator works and the available parameters
- saveIfAnnotationHas.key and saveIfAnnotationHas.value (string) - Exclude namesapces that have these key,val pair in their annotations.
- olderThan (int) - This number tells the operator if selected namespaces ( excluding the ones from above ) is older than or equal to x hours, delete it.
- dryRun (bool) - Can be turned on to just see what will happen, no namespace will be deleted if this is set to true