Creating a Base Image with bld.sh

bld.sh runs the extend installer to create a base image that includes a version of the Linux operating system. The base image includes products for the Compiler, AcuRCL, AcuConnect, AcuToWeb, AcuServer, and license files for these products.

Usage

bld.sh IacceptEULA

Parameter

IacceptEULA
Indicates the acceptance of the End User License Agreement (EULA). This parameter is required.

bld_linux_x64.env

bld.sh uses the following information included from bld_linux_x64.env:

# Version of extend
EXTEND_VERSION=10.5.0

# Name of the Linux operating system used by the base image
OS=ubuntu

# Name of the Linux repository tag used to create the base image
BASEOSIMAGE=ubuntu:20.04

# Name of the Dockerfile used to create the base image
DOCKERFILE=Dockerfile_linux_x64

# Complete base image reference name
# like microfocus/extend:ubuntu_10.5.0_x64
BASEIMAGE=microfocus/extend:ubuntu_${EXTEND_VERSION}_x64

# Complete application image reference name
# like microfocus/extend-app:ubuntu_10.5.0_x64
APPIMAGE=microfocus/extend-app:ubuntu_${EXTEND_VERSION}_x64

# Name of the Linux extend setup program
SETUPEXE=setup_acucob1050pmk59shACU

# Name of the directory containing the license files
LICENSE_DIRECTORY=aculic_pmk59

# Name of the installation directory
INSTALL_DIRECTORY=/opt/microfocus/extend

podman Build Command

bld.sh runs the podman build command to create the base image:

podman build
	--tag $BASEIMAGE \
	--format docker \
	--build-arg BASEOSIMAGE=$BASEOSIMAGE \
	--build-arg ACCEPTEULA=$ACCEPTEULA \
	--build-arg SETUPEXE=$SETUPEXE \
	--build-arg LICENSE_DIRECTORY=$LICENSE_DIRECTORY \
	--build-arg INSTALL_DIRECTORY=$INSTALL_DIRECTORY \
	--build-arg EXTEND_VERSION=$EXTEND_VERSION \
	--file $DOCKERFILE .

Where:

--tag
Sets a name for the base image that gets built.
--format docker
Uses the Docker format for the built image's manifest and configuration data.
--build-arg
Sets variables that get used in the Dockerfile specified by the --file option.
--file
Specifies the name of the Dockerfile that contains the base image creation commands.
.
Sets the current directory as the directory in which to look for file and subdirectories.

Dockerfile_linux_x64

The Dockerfile_linux_x64 file contains the following commands to create the image:

Note: ARG specifies arguments that are used by other Dockerfile commands. Their values can be overridden with the --build-arg options to the podman build command in bld.sh.
# Name of the repository tag used to create the base image
# Can be overridden with the --build-arg option in bld.sh
ARG BASEOSIMAGE=${BASEOSIMAGE}

# Use the base operating system image to build the base extend image
FROM ${BASEOSIMAGE}

# Default Dockerfile values
# Values can be overridden with the --build-arg options in bld.sh
# These need to come after the FROM command or else they will not have a value
ARG ACCEPTEULA=sorryIDontAcceptEULA
ARG SETUPEXE=${SETUPEXE}
ARG LICENSE_DIRECTORY=${LICENSE_DIRECTORY}
ARG INSTALL_DIRECTORY=${INSTALL_DIRECTORY}
ARG EXTEND_VERSION=${EXTEND_VERSION}

# Embed the label information into the base image for identification.
# This can be viewed with podman image inspect <image-id>
LABEL vendor="Micro Focus" \
      com.microfocus.name="extend" \
      com.microfocus.version="$EXTEND_VERSION" \
      com.microfocus.eula.url="https://supportline.microfocus.com/licensing/lvcontract.aspx" \
      com.microfocus.is-base-image="true"

# Copy the extend setup to a temporary directory in the image
COPY ${SETUP_EXE} /tmp/ 

# Add execute permission to the extend setup
RUN chmod +x /tmp/${SETUP_EXE}

#Create the installation directory before running the setup
RUN mkdir -p ${INSTALL_DIRECTORY}

# Install the extend products, providing answers to the prompts,
# redirecting the output to a file in the temporary directory
RUN	(echo "y"; echo "${INSTALL_DIRECTORY}") | /tmp/${SETUPEXE} > /tmp/${SETUPEXE}.out 2>&1

# Copy the extend license files to the bin directory
COPY ["${LICENSE_DIRECTORY}", "${INSTALL_DIRECTORY}/bin/"]

# Install packages needed to run 32-bit applications like python
# which is needed for AcuToWeb
RUN	dpkg --add-architecture i386 && \
	apt-get update -y && \
	apt-get install -y libc6:i386 libncurses5:i386 libstdc++6:i386 zlib1g:i386
If bld.sh runs without errors, you can use the following command to list all of the images:
podman images 

The base image has the following repository and tag name:

REPOSITORY TAG
localhost/microfocus/extend ubuntu_10.5.0_x64