Skip to content

Don't try to delete non-existing K8s resources

Rémy Coutable requested to merge fix-automated-review-app-cleanup into master

What does this MR do?

I detected this small bug while investigating an increase in the number of nodes in the review-apps cluster (https://gitlab.slack.com/archives/CMA7DQJRX/p1617290099074200?thread_ts=1617280667.070700&cid=CMA7DQJRX).

This led to errors like:

Running command: `kubectl delete pvc --namespace "review-apps" --now --ignore-not-found --wait=false `
/builds/gitlab-org/gitlab/tooling/lib/tooling/kubernetes_client.rb:119:in `run_command': The `kubectl delete pvc --namespace "review-apps" --now --ignore-not-found --wait=false ` command failed (status: pid 282 exit 1) with the following error: (Tooling::KubernetesClient::CommandFailedError)
error: resource(s) were provided, but no name, label selector, or --all flag specified
Edited by Rémy Coutable

Merge request reports

Loading