Files
kata-containers/tools/packaging/scripts
Fabiano Fidêncio 908c53f79a packaging: make builder base-image registry substitutable for CI
The static-build builder Dockerfiles (agent, kernel, qemu, shim-v2, ovmf,
tools, virtiofsd, busybox, codegen, coco-guest-components, pause-image) and
the agent codegen image hardcoded their base images from Docker Hub
(ubuntu/alpine/busybox/golang). On a builder-image cache miss in CI these
pulls are subject to Docker Hub rate limiting.

Parameterize every FROM with `ARG IMAGE_REGISTRY=docker.io` +
`FROM ${IMAGE_REGISTRY}/...` (default unchanged, so local builds keep using
Docker Hub) and have each component build script forward the value via a new
get_image_registry_build_arg() helper in scripts/lib.sh (only emitted when
IMAGE_REGISTRY is set). kata-deploy-binaries-in-docker.sh forwards
IMAGE_REGISTRY into the build container.

The build-kata-static workflows set IMAGE_REGISTRY=ghcr.io/kata-containers
per-component on the Docker-Hub-only jobs (build-asset, shim-v2, tools) and,
for rootfs, on every asset except cbl-mariner. To keep the fedora
image-builder on its own registry, it now uses a dedicated
IMAGE_BUILDER_REGISTRY (default registry.fedoraproject.org) instead of
sharing IMAGE_REGISTRY, so the rootfs ubuntu/alpine base can be mirrored
without breaking the fedora- and mcr-based image builds.

Authored-by: Cursor <cursor@cursor.com>
Signed-off-by: Fabiano Fidêncio <ffidencio@nvidia.com>
2026-06-11 21:20:49 +02:00
..

Packaging scripts

This directory contains useful packaging scripts.

configure-hypervisor.sh

This script generates the official set of QEMU-based hypervisor build configuration options. All repositories that need to build a hypervisor from source MUST use this script to ensure the hypervisor is built in a known way since using a different set of options can impact many areas including performance, memory footprint and security.

Example usage:

  $ configure-hypervisor.sh qemu