openziti / ziti-builder

Cross-compile builder container image for ziti-tunnel-sdk-c
Apache License 2.0
2 stars 0 forks source link

Builder container for Ziti projects

This container image has CMake and other utilities and libraries installed for cross-compiling Ziti projects with GLIBC 2.27. The image is automatically published to Docker Hub as openziti/ziti-builder:latest (and :main) when merging to main.

Developing this container image

Building this image is unnecessary for building the Ziti projects that use this image. This section is about releasing an improvement for the image to Docker Hub for developers and CI to use with all Ziti projects that employ this image to build the project.

Build the image for local testing

# optionally substitute podman or nerdctl for docker
docker build . --tag ziti-builder-test

Run the local test image to cross-compile a Ziti project

Change to the directory of the Ziti project you want to test building the default target. Run your local test image with that project mounted in the correct path and your UID to avoid permissions conflicts in the build output directory.

# optionally substitute podman or nerdctl for docker
docker run \
    --rm \
    --user="${UID}" \
    --volume="${PWD}:/github/workspace" \
    ziti-builder-test ./ziti-builder.sh

Publish the image to Docker Hub

  1. Create a pull request targeting the main branch.
  2. Merge the pull request to main.
  3. Create a meaningful release tag in GitHub that matches the regex v[0-9]+.[0-9]+.[0-9]+.
  4. The release will trigger a GitHub Action that builds and publishes the image to Docker Hub.

GLIBC Compatibility

Ziti projects that build with this image will produce artifacts that require GLIBC >= 2.31.

This excludes Ubuntu Bionic and CentOS 7.