Customizing container images offline - airgap environment

Customize the Sterling™ Order Management System Software images in an airgap environment with no internet access by either loading the images manually or setting up a local or private registry.

Before you begin

Before you customize the images by using the generateImages.sh script, the UBI and WebSphere Liberty images must be available for the build to use these images.

About this task

You can store or load the images in several ways. The Liberty versions that are mentioned in the following examples update over time. Ensure that you update these values to the supported versions. For more information about supported Liberty versions, see Software Product Compatibility Reports.
Remember: Starting 8 March 2024 (10.0.2403.0) release, when customizing images, you no longer need to apply the --privileged flag, for Podman commands. For Docker, continue using the --privileged flag, until further notice.

Procedure

  • Method 1: Loading the images manually to the om-base container
    1. Save the images as archives as shown in the following example:
       # save as archives 
      podman save -o ubi8.tar registry.access.redhat.com/ubi8/ubi
      podman save -o liberty.tar icr.io/appcafe/websphere-liberty:23.0.0.12-kernel-java8-ibmjava-ubi
    2. Copy the images to the om-base container.
       # copy images to the om-base container
      podman cp ubi8.tar <your om-base container name>:<path inside the container>
      podman cp liberty.tar <your om-base container name>:<path inside the container>
    3. Run the following commands.
      # exec to your container
      # from inside your container
      buildah pull docker-archive://<path inside the container>/ubi8.tar
      buildah pull docker-archive://<path inside the container>/liberty.tar
    4. Verify that the images are present in the om-base container.
      # check to ensure the images are present
      buildah images
  • Method 2: Setting up a local or private registry to store the images
    1. Set up a local registry. This is the registry that buildah pull the images from. Ensure that your om-base container has access to this registry.
    2. Mirror the following images to your local or private registry.
      • registry.access.redhat.com/ubi8/ubi
      • icr.io/appcafe/websphere-liberty:23.0.0.12-kernel-java8-ibmjava-ubi
    3. Run the ./generateImages.sh script with the following flags set.
      • BUILDER_IMAGE: The ubi8 image from your local or private registry. It defaults to registry.access.redhat.com/ubi8/ubi.

        For example, --BUILDER_IMAGE=my.local.registry.com/ubi8/ubi:latest

      • LIBERTY_IMG: The liberty image that is to be used. It defaults to icr.io/appcafe/websphere-liberty.

        For example, --LIBERTY_IMG=my.local.registry.com/websphere-liberty.

      • LIBERTY_TAG: The liberty tag that is to be used. It defaults to 23.0.0.12-kernel-java8-ibmjava-ubi.

        For example, --LIBERTY_TAG=23.0.0.12.