Skip to content

Discussion on Github Actions, Packages, and Buildah #723

@sloretz

Description

@sloretz

Given the effort that's been made to try to solve #112 , I looked at creating images with Github Actions using buildah and hosting them on Github Packages. It seems like a pretty good option to me, so I'm opening a ticket to discuss if the official images could benefit from any of it.

https://github.com/sloretz/ros_oci_images

About Github Packages I learned:

  • Images are associated with an account or organization, NOT a repo. Official packages could be named ghcr.io/osrf/ros to make an image named ros in the ghcr.io/osrf registry
  • Pushing new versions to Github packages seems to be rate limited. Trying to push all images for a ROS distro at once (12 images + 6 manifests for Rolling) requires backoff and retry logic that might wait for 10 minutes to get a successful push. Pushing them one at time as they are built (roughly 1 image every few minutes) seems to be no problem.

About buildah I learned:

  • Recent versions of buildah are great, but the CLI has already changed a bit since the version in Jammy. I pinned to a specific version and built it from source.
  • Be default all layers are squashed in buildah, so you don't have to work as hard to clean up intermediate layers if you don't want to.
  • I found using buildah and Containerfile/Dockerfile with buildah easy to understand. To be honest I've never really felt like I understood the path from osrf/docker_templates to the Dockerfiles here.
  • I had to play around a bit to find a version of qemu-user-static that would successfully build all of the ROS images. Using Fedora 39 with qemu-user-static 8.1.3 I was not able to build all images on all architectures. The version on ubuntu-latest in Github Actions works fine though.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions