-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create tool to remove unused resources #827
Comments
Note, any image that isn't referenced in https://github.com/taskcluster/community-tc-config/blob/main/config/imagesets.yml is a candidate for removal. But there are also other entities, like snapshots, resource groups, etc, that can also be cleaned up. Another thing we might want to do is read all worker pool definitions and retain any images mentioned in any of them (in case there are worker pools that were not generated by this repo and don't have entries in imagesets.yml). Maybe we can consistently tag all resources that we create in community-tc-config repo, and then only delete ones that we definitely created. But we could probably at least report on images that we didn't create that also aren't referenced in any worker pool or imagesets.yml so we discover if anything else is cluttering up our accounts. |
i've done a partial cleanup in azure just now, by killing all VMs (so ones needed get respawned by worker manager) - in case image building had left any running. Then i listed all images in rg-tc-eng-images (335 of them) and removed any that appeared in imagesets.yml (26 of them), and then iterated through those 309 remaining ones, and deleted them. This is only azure, I haven't done any aws or gcp cleanup. But for sure, we want to script this. I just needed to do it manually now as I wasn't able to build some images due to resource constraints. |
|
To make rollbacks easier #819 was created which removed all the code that would automatically delete old resources. We decided to remove this deletion code in favor of a tool/script that will go through and delete these resources as we see fit. For example, once we have images being properly tested before rolling out, we could auto-delete old resources.
The text was updated successfully, but these errors were encountered: