ros-realtime-rpi4-image icon indicating copy to clipboard operation
ros-realtime-rpi4-image copied to clipboard

CI for building and releasing images

Open shuhaowu opened this issue 3 years ago • 4 comments

The build process takes about 10-15 minutes on CI without compressing the image. The resulting image is then 8GB, which very large. Github releases have a 2GB/file limit, so we should go under that. When I tried to xz the image, If I recall, I got it to about 1.7GB, which would be below that limit if I'm not wrong. In that case, we can post these images directly to Github releases (only for tags tho). Not sure how Github will feel once we start building more images tho.

That said, the xz process takes up at least 15 minutes on CI without including the build process, as GH's CI runner is only 2 cores when I checked. This means a build would be more than 30 minutes. GH CI only offers 2000 minutes/month, which means <100 builds/month. This might be good enough, especially if the build is limited to tags ans master branch only (depends on the number of images)? Although I suspect this repository will experience more burst of activities, which might be annoying to deal with. Still we might be able to start here for now.

One idea is to have a self-hosted runner running somewhere. This will allow unlimited time. I might be able to set something up on my home server if we don't abuse it... Coupled with the 2GB/file limit, it might be an okay solution.

shuhaowu avatar Nov 03 '21 22:11 shuhaowu

@LanderU: use https://github.com/ros-realtime/linux-real-time-kernel-builder as a reference to do the release

carlossvg avatar Feb 21 '22 17:02 carlossvg

Hello. I just wanted to add my input in regards of:

Not sure how Github will feel once we start building more images tho.

I have a project (that needs love) that was producing daily releases of more than 2GB by splitting the images in smaller files. I used lzma as compression as it had a decent tradeoff between time compressing and size. Example: https://github.com/awesomebytes/ros_overlay_on_gentoo_prefix/releases

So I think it should be fine. No one ever complained about it from Github.

awesomebytes avatar Oct 25 '22 07:10 awesomebytes

Interesting and clever idea. Not sure if is needed for the time being because our image is under 2GB. If we want to release desktop images, it'll be above 2GB.

However, having a splitted file is not exactly beginner friendly either. Given that installing ubuntu-desktop is relatively easy, and the fact that ubuntu desktop performance on the rpi4 is not exactly the best, let's maybe defer this until we have people who request for this feature and maybe if someone can donate bandwidth/space to host a desktop version of our image.

shuhaowu avatar Oct 25 '22 10:10 shuhaowu

Providing instructions on how to install desktop may be enough I think :) at least for the time being

awesomebytes avatar Oct 25 '22 11:10 awesomebytes