Created
April 13, 2023 11:33
-
-
Save roman4ello/8208f40edafcda6943e875aae02b1b8c to your computer and use it in GitHub Desktop.
GCP cloud run delete all non active revisions
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
REVS=`gcloud run revisions list --filter="status.conditions.type:Active AND status.conditions.status:'False'" --format='value(metadata.name)'` | |
for rev in `echo $REVS`; do | |
echo $rev | |
gcloud run revisions delete $rev --quiet & | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment