zuul-jobs/roles/build-container-image/common.rst
vass 2cb9f249a8 Rename install-podman to ensure-podman for consistency
The old role will be kept and include ensure-podman for backwards-compatability.

Change-Id: I21cfdfef4a88f66f51d139abed04f70b3228a22d
2020-04-04 15:41:29 -04:00

4.7 KiB

This is one of a collection of roles which are designed to work together to build, upload, and promote container images in a gating context:

  • :zuulbuild-container-image: Build the images.

Note

Build and upload roles are forthcoming.

The :zuulbuild-container-image role is designed to be used in check and gate pipelines and simply builds the images. It can be used to verify that the build functions, or it can be followed by the use of subsequent roles to upload the images to a registry.

They all accept the same input data, principally a list of dictionaries representing the images to build. YAML anchors can be used to supply the same data to all three jobs.

Use the :zuulensure-docker or :zuulensure-podman role to install Docker or Podman before using these roles.

Role Variables

The default container filename name to use. Serves as the base for :zuulbuild-container-image.container_images.container_filename. This allows a global overriding of the container filename name, for example when building all images from different folders with similarily named containerfiles.

If omitted, the default depends on the container command used. Typically, this is Dockerfile for docker and Containerfile (with a fallback on Dockerfile) for podman.