Dockerfiles for ActiveMatrix Service Grid - Container Edition

The deployment package contains the following Dockerfiles and scripts for building images of ActiveMatrix Service Grid - Container Edition components:

Executable File Purpose of the File
amsgce-runtime-<version>/runtime/build/build_amxce To build the Docker image of ActiveMatrix Service Grid - Container Edition application.
amsgce-runtime-<version>/runtime/build/s2i/build_amxce_s2i To create the ActiveMatrix Service Grid - Container Edition builder Docker image by using Source-To-Image(S2I) tool. By using the S2I tool, you can create a builder image, which contains an operating system, all required libraries, and <TIBCO_HOME> with all the required scripts. You can use the builder image as a base image to build a Docker image of applications. For more information about Source-To-Image(S2I) tool, see Source-to-Image (S2I) documentation.
amsgce-runtime-<version>/applicationConfigurator/build/build_amxce To build the Docker image of the Application Configurator.
amsgce-runtime-<version>/teaagent/build/build_amxceteaagent To build the Docker image for Application Monitor agent.

The following table lists Dockerfiles provided with ActiveMatrix Service Grid - Container Edition for different platforms, with the list of the script files that are using the Dockerfile, and the type of the container. The default base image used is Alpine Linux with Java 11. You can specify the other Dockerfile than the default one by using the following command:

Example:

./build_amxce --image_tag "bookstore:1.0" --dockerfile Dockerfile_ubi8_java11
 
Dockerfile Details
Location: amsgce-runtime-<version>/runtime/docker
Dockerfile_alpine_java11

Platform: Alpine Linux

Used for Creating Docker Image of: ActiveMatrix Service Grid - Container Edition Application

Associated executable file: build_amxce

Dockerfile_ubi7_java11

Platform: Red Hat Universal Base Image

Used for Creating Docker Image of: ActiveMatrix Service Grid - Container Edition Application

Associated executable file: build_amxce

Dockerfile_ubi8_java11

Platform: Red Hat Universal Base Image

Used for Creating Docker Image of: ActiveMatrix Service Grid - Container Edition Application

Associated executable file: build_amxce

Dockerfile_ubuntu_java11

Platform: Ubuntu

Used for Creating Docker Image of: ActiveMatrix Service Grid - Container Edition Application

Associated executable file: build_amxce

Dockerfile_alpine_glibc_java11

Platform: Alpine Linux

If you want create image with Alpine Linux and TIBCO JRE or Oracle JRE, you need to install glibc.

Use this Docker file which has steps to install glibc.

Associated executable file: build_amxce

Location: amsgce-runtime-<version>/runtime/docker/s2i
Dockerfile_alpine_java11

Platform: Alpine Linux

Used for Creating Docker Image of: ActiveMatrix Service Grid - Container Edition Builder Image

Associated executable file: build_amxce_s2i

Dockerfile_ubi7_java11

Platform: Red Hat Universal Base Image

Used for Creating Docker Image of: ActiveMatrix Service Grid - Container Edition Builder Image

Associated executable file: build_amxce_s2i

Dockerfile_ubi8_java11

Platform: Red Hat Universal Base Image

Used for Creating Docker Image of: ActiveMatrix Service Grid - Container Edition Builder Image

Associated executable file: build_amxce_s2i

Dockerfile_ubuntu_java11

Platform: Ubuntu

Used for Creating Docker Image of: ActiveMatrix Service Grid - Container Edition Builder Image

Associated executable file: build_amxce_s2i

Dockerfile_alpine_glibc_java11

Platform: Alpine Linux

If you want create image with Alpine Linux and TIBCO JRE or Oracle JRE, you need to install glibc.

This Docker file has steps to install glibc.

Associated executable file: build_amxce_s2i

Location: amsgce-runtime-<version>/teaagent/docker
Dockerfile_alpine_java11

Platform: Alpine Linux

Used for Creating Docker Image of: Application Monitor Agent

Associated executable file:

build_amxceteaagent

Dockerfile_ubuntu_java11

Platform: Ubuntu

Used for Creating Docker Image of: Application Monitor Agent

Associated executable file:

build_amxceteaagent

Dockerfile_alpine_glibc_java11

Platform: Alpine Linux

If you want create image with Alpine Linux and TIBCO JRE or Oracle JRE, you need to install glibc.

Use this Docker file which has steps to install glibc.

Associated executable file:

build_amxceteaagent

For more information about Dockerfile structure, see Docker Documentation.

Only the following base images and versions are tested in ActiveMatrix Service Grid - Container Edition 1.0.1:

Base Image Version
Alpine Linux

3.12

3.9.6

Ubuntu 18.04.5
Red Hat UBI

8.2

7.8

The following Platforms are supported to build the Docker images:

The following sections describe Environment Variables and Labels for ActiveMatrix Service Grid - Container Edition Docker images.

Environment Variables (ENV)

The ENV instruction is used to set the environment variables in the Dockerfile. These variables consist of key-value pairs that can be accessed from within the container by scripts and applications alike. The syntax for the ENV instruction is:

ENV key value

You can view environment variables and labels for a Docker image by using Docker inspect command:

docker image inspect <Docker_Image_Name:tag>

The default ActiveMatrix Service Grid - Container Edition Dockerfiles have the following common environment variables:

Environment variables Description
TIBCO_AMXCE_VERSION

ActiveMatrix Service Grid - Container Edition version

TIBCO_AMXCE_APPTEMPLATE

Name of the application template from which the application is created.

Each application is associated with a single application template.

TIBCO_AMXCE_APPTEMPLATE_VERSION

Version of the application template.

TIBCO_AMXCE_NODE_HTTP_PORTS

Exposed ports of the container. Port 9998 is added by default in the exposed ports, which is used for monitoring application.

Default: 9998

TIBCO_AMXCE_UID

Build date timestamp.

This is used to create the default keystore password.

TIBCO_AMXCE_APPLICATION_LOCATION

Location where applications are stored in the Docker image.

Default: /opt/tibco/tibco.home/data/applications/daas

Labels used in ActiveMatrix Service Grid - Container Edition Docker Files

The LABEL instruction adds metadata to an image. A LABEL is a key-value pair.

Label Description
maintainer

Describes author of the Docker image.

Default: Cloud Software Group, Inc.

tibco.amxce.app_description Description of the application from configuration YAML file.
tibco.amxce.app_template_name Name of the application template from which the application is created.
tibco.amxce.app_template_version

Version of the application template from which the application is created.

This label is set from application DAA. If configuration YAML file and DAA have a different application template version, then the label is set from the DAA application template version.

tibco.amxce.build_date Date and time stamp when the Docker image is built.
tibco.amxce.env_name Environment name in which the application is running in the container.
tibco.amxce.node_name Node on which the application container is running.
tibco.amxce.version Version of ActiveMatrix Service Grid - Container Edition

Labels and Environment Variables for S2I Builder Image

Environment Variables

Environment Variable Description
TIBCO_AMXCE_VERSION ActiveMatrix Service Grid - Container Edition version
TIBCO_AMXCE_UID

Build date timestamp.

TIBCO_AMXCE_APPLICATION_LOCATION

Location where applications are stored in the Docker image.

Default: /opt/tibco/tibco.home/data/applications/daas

TIBCO_AMXCE_DATA_FOLDER

Root location where all ActiveMatrix Service Grid - Container Edition files are stored in the Docker image.

Default: /opt/tibco/tibco.home/data

Builder Image Labels

Label Description
org.opencontainers.image.revision Source control revision identifier for the packaged software.
org.opencontainers.image.created

Date and time on which the image was built.

io.openshift.s2i.scripts-url

Location of S2I build script in the Docker image.

Default: image:///usr/libexec/s2i

Labels for Application Image Created from Builder Image

Label Description
io.openshift.expose-services Exposed ports of the container
org.opencontainers.image.created

Image build date and time stamp.

Format: date -u +'%Y-%m-%dT%H:%M:%SZ

org.opencontainers.image.vendor Name of the distributing organization that is TIBCO.
org.opencontainers.image.title Name of the application template from which the application is created.
org.opencontainers.image.description Application description