openwrt-openwisp-monitoring icon indicating copy to clipboard operation
openwrt-openwisp-monitoring copied to clipboard

[ci] Delete old builds

Open nemesifier opened this issue 4 years ago • 6 comments
trafficstars

@devkapilbansal is there a way to remove the old builds? I think we can keep stable releases (which we shall name differently), but we should highly limit the build results because space has a cost, I think we can keep the last 5 builds.

nemesifier avatar Sep 19 '21 23:09 nemesifier

I am not sure but there should be some way. I will try to find more about it

devkapilbansal avatar Sep 24 '21 16:09 devkapilbansal

This might be helpful: https://cloud.google.com/storage/docs/object-versioning

pandafy avatar Sep 30 '21 20:09 pandafy

This might be helpful: https://cloud.google.com/storage/docs/object-versioning

I think it can be great if we don't want to show builds to users. I mean is it possible to show all versions of the object to the user without some workaround?

What I am thinking of is to use some cloud functions to manage this thing. :thinking:

devkapilbansal avatar Sep 30 '21 20:09 devkapilbansal

I'll read more on this and get back after the weekend. Please feel free to proceed if you are able to make it work.

pandafy avatar Sep 30 '21 20:09 pandafy

Hi @nemesisdesign We can do it using Cloud Functions. A custom script can be executed that will be triggered on a file upload. We can either keep stable releases in a different path like {bucket-name}/release or name them differently, whatever sounds good

devkapilbansal avatar Feb 26 '23 13:02 devkapilbansal

I would not change paths for now but only concern with deleting very old builds (eg: > 2 years).

nemesifier avatar Feb 28 '23 18:02 nemesifier