Docker is a popular platform for building, sharing and running applications. Since the Docker container packages applications with all their libraries and dependencies, the application can run on any Docker host in any supported environment. Among the benefits of this strategy are:
  • Docker containers are faster to create and quicker to start.
  • Docker scales efficiently when demand for your application grows.
  • Corticon Server deployed to Docker as a web application can be accessed as a REST or a SOAP service.
Note: Prepare to deploy Corticon Server to Docker by getting and running Docker for your platform at https://docs.docker.com/get-docker/. Remember to check that Docker is running every time you intend to use your repository.

Configure Corticon Docker

A Corticon Server install provides the Docker configuration file, Dockerfile, and the .war files for Corticon Server and Corticon Web Console.

For download information, see Download installer packages.

Corticon Server on Docker

  1. Navigate to: C:\Progress\Corticon 7.2\Server\Deploy\Docker.
  2. Edit Dockerfile. The Corticon configuration is pre-configured to deploy Corticon Server to a base Tomcat 9.0 image. You can adjust and add to the configuration to suit your installation.
  3. Open the Server's Dockerfile in your preferred text editor:
    ###Copyright 2005-2024 Progress Software Corporation and/or its subsidiaries and affiliates. All rights reserved.
    
    # Specify the tomcat image version to pull from DockerHub 
    FROM tomcat:9.0-jre17
    ##This will derive the latest 9+ image of Tomcat with jre 17 version
    
    USER root
    
    # Open port 8080
    EXPOSE 8080
    
    ################Setting Corticon Home and Work Directory ########################
    ##Create the directory CORTICONWORK
    #RUN mkdir /usr/local/tomcat/CORTICONWORK
    
    ##SET CORTICON HOME 
    #ENV CATALINA_OPTS="$CATALINA_OPTS -DCORTICON_HOME=/usr/local/tomcat/CORTICONWORK"
    
    ## Similarly you can SET CORTICON WORK DIR using the -DCORTICON_WORK_DIR
    #ENV CATALINA_OPTS="$CATALINA_OPTS -DCORTICON_WORK_DIR=<PATH_TO_WORK_DIR>"
    
    #########################################################
    
    ## Copy Corticon war files to work directory
    COPY axis.war /usr/local/tomcat/webapps
    
    ########### Updating Corticon License ####################
    
    ##Create a Directory to copy the license
    RUN mkdir /usr/local/tomcat/LicenseCorticon
    
    ##Copy the CcLicense.jar to the directory created
    #COPY CcLicense.jar /usr/local/tomcat/LicenseCorticon
    
    ##Set the environment variable to update the license for the Corticon Server
    #ENV CATALINA_OPTS="$CATALINA_OPTS -DCORTICON_LICENSE=/usr/local/tomcat/LicenseCorticon/CcLicense.jar"
    
    ##############################################################
    ## Create Deploy and cdd folders
    RUN mkdir /usr/local/Deploy
    RUN mkdir /usr/local/tomcat/cdd
    
    ## To deploy Decision services, copy the eds file and cdd file to the CDD directory
    #ADD Order.eds /usr/local/tomcat/cdd/
    #ADD OrderProcessing.cdd /usr/local/tomcat/cdd/
    
    # To enable Corticon Server to use the brms.properties, copy this file to the Corticon Work dir
    #ADD brms.properties /usr/local/tomcat/
    
    The predefined settings for Corticon Server on Docker are as follows:
    • FROM statement to specify the base image to be used for this container. The docker file bundled uses a public tomcat9 version and jre17 version, imaged from Docker hub. You can choose any other supported image from docker hub that is supported in the Corticon release or build your own. Refer to the Progress Software web page Corticon Supported Platforms Matrix to review the currently supported Corticon Studio operating systems, and Eclipse versions.
    • USER is set to root to ensure that the container has full control of the host system.
    • EXPOSE lets you specify the network port on which Docker will listen at runtime.
    • COPY The next step copies axis.war, tomcat.
    • RUN mkdir sets up the required directories.
    • #ADD Order installs the Decision Service file and the corresponding CDD. Remove the # tag to enable the actions.

Corticon Server on Web Console

  1. Navigate to: C:\Progress\Corticon 7.2\WebConsole\Deploy\Docker.
  2. Edit Dockerfile. The Corticon configuration is pre-configured to deploy Corticon Server to a base Tomcat 9.0 image. You can adjust and add to the configuration to suit your installation.
  3. Open the Server's Dockerfile in your preferred text editor: Open the Server's Dockerfile in your preferred text editor:
    ###Copyright 2005-2024 Progress Software Corporation and/or its subsidiaries and affiliates. All rights reserved.
    
    # Specify the tomcat image version to pull from DockerHub 
    FROM tomcat:9.0-jre17
    ##This will derive the latest 9+ image of Tomcat with jre 17 version
    
    USER root
    
    # Open port 8080
    EXPOSE 8080
    
    ################Setting Corticon Home and Work Directory ########################
    ##Create the directory CORTICONWORK
    #RUN mkdir /usr/local/tomcat/CORTICONWORK
    
    ##SET CORTICON HOME 
    #ENV CATALINA_OPTS="$CATALINA_OPTS -DCORTICON_HOME=/usr/local/tomcat/CORTICONWORK"
    
    ## Similarly you can SET CORTICON WORK DIR using the -DCORTICON_WORK_DIR
    #ENV CATALINA_OPTS="$CATALINA_OPTS -DCORTICON_WORK_DIR=<PATH_TO_WORK_DIR>"
    
    #########################################################
    
    ## Copy Corticon war files to work directory
    COPY corticon.war /usr/local/tomcat/webapps
    
    
    ###########################################################
    ####### Web Console (corticon.war) specific settings ######
    
    ##Create a etc directory
    #RUN mkdir /usr/local/tomcat/CORTICONWORK/etc
    
    ## Copy the logback.xml to CORTICONWORK Directory
    #COPY logback.xml /usr/local/tomcat/CORTICONWORK/etc
    
    ## Copy the CorticonServerConsoleConfig.groovy to CORTICONWORK Directory
    #COPY CorticonServerConsoleConfig.groovy /usr/local/tomcat/CORTICONWORK/etc
    
    The settings are similar to the preceding ones for Corticon Server on Docker.

Setting Corticon Home and Work Directory

You can set the Corticon Home and Corticon Work directory in the Docker file to point to a preferred location:
  1. Add the lines:
    RUN mkdir /usr/local/tomcat/CORTICONWORK
    ENV CATALINA_OPTS="$CATALINA_OPTS -DCORTICON_HOME=/usr/local/tomcat/CORTICONWORK/"
    ENV CATALINA_OPTS="$CATALINA_OPTS -DCORTICON_WORK_DIR=/usr/local/tomcat/CORTICONWORK/"
  2. Adjust the ADD to ensure that preferences are set in a brms.properties file are copied to the Corticon Work Directory.

Update the Corticon license

You need to copy the license to the container and then update the environment variable.

To add or update the license:

  1. Locate your valid Corticon license for the Server/Web Console version.
  2. Add the lines:
    RUN mkdir /usr/local/tomcat/LicenseCorticon
    COPY CcLicense.jar /usr/local/tomcat/LicenseCorticon
    ENV CATALINA_OPTS="$CATALINA_OPTS -DCORTICON_LICENSE=/usr/local/tomcat/LicenseCorticon/CcLicense.jar"
    After the configuration is complete, you need to provide the files you specified, and then build the docker image.

Provide specified files

After the preceding steps, you need to copy the specified files into the Docker folder, PROGRESS_CORTICON_X.x_DOCKER:

  • CcLicense.jar from C:\Progress\Corticon_Server_Work_7.2\license\Server\
  • brms.properties from C:\Progress\Corticon_Server_Work_7.2
  • ProcessOrder.eds and OrderProcessing.cdd from the Order Processing sample.

Build the Docker container image from the Dockerfile

  1. Open a Command Prompt window as administrator to the root of the Docker installation.
  2. If you are replacing an existing image, type:
    docker container prune	
    and then type y to complete the deletion.
  3. Then, for the new image where corticondemo is your preferred name, type:
    docker ps -a
    docker build -t corticondemo .

For more Docker documentation and options supported with the Docker build command, reference the docker documentation at https://docs.docker.com/.

Run the Docker container

  1. Open a Command Prompt window as administrator to the root of the Docker installation.
  2. Type:
    docker run -p 8080:8080 corticondemo	
Note: Docker has many options for run. See https://docs.docker.com/engine/reference/commandline/run/.

The Tomcat console output shows the server startup log lines.

Confirm the Server operation

Check the Corticon server by accessing the Corticon ping REST end point on the browser:

http://localhost:8080/axis/corticon/server/ping

When the server is running, the REST/GET request returns JSON with the uptime as:

{"uptime" : <time in milliseconds>}

To check that the license has been updated properly, you can check the server properties using the REST end point

http://localhost:8080/axis/corticon/server/getProperties

The REST response returns JSON with the Server properties. When the license has been updated, the licenseFilePath attribute in the JSON has the updated path:

"licenseFilePath":"/usr/local/tomcat/LicenseCorticon/CcLicense.jar",

In the Web Console, connect to the running server in this example as:

The Server Details view shows the license and the properties.

Other platforms

The steps needed to successfully deploy docker to a Tomcat server image can be transformed to other supported application servers listed in the Corticon Supported Platforms Matrix . To deploy Corticon to the different application servers, refer to the Corticon Knowledge Base entry Corticon Server 7.x sample WAR installation for different Application Servers for settings on specific application servers.

The configurations specific to deploying a web-app to a different image can differ based on the requirements of the image. However, the Corticon-specific configurations like setting the CORTICON_HOME and CORTICON_WORK_DIR or updating the license stay the same. You still must pass the environment variables like -DCORTICON_LICENSE to update the license or -DCORTICON_HOME to use a different location for Corticon home.

The Dockerfile can be customized to fit your business needs on any supported OS/application server Docker image.