Steps to Build and Run the Docker Image
-
Download the domain binary files, Service Layer Distribution as mentioned in the Pre-requisites section of this document.
- Extract the Service distribution.
- Create a directory named externallibs to place the third-party application libraries, configuration, and the property files required.
-
Copy the downloaded Service distribution zip under the externallibs/zip.
- Copy the following configuration files from <Service distribution zip>/conf directory into the externallibs/conf directory:
- EDKeyValue.dat
- Encryption.properties
- ESAPI.properties
- Service.properties
- service-coherence-cache-config.xml
- service-coherence-config.xml
- logging.properties
- Copy the following files from the <Service distribution zip>/libs directory into the externallibs directory:
commons-logging-1.2-1e55e8f.jar
eclipselink-2.7.10.jar
jakarta.persistence-2.2.3.jar
Note: Rename all the jars without version names. This is to avoid version updates in the Docker script.
Example
commons-logging.jar
eclipselink.jar
jakarta.persistence.jar
-
If the Service Layer application is ATP compliant, then copy the required ATP (Autonomous Transaction Processing) database files under the externallibs/shared directory.
The sample folder structure is as follows:
- Under the ojdbc folder:
-
Copy all the libs to the ojdbc folder.
-
Under the wallet folder:
Note: Maintain the externallibs folder and place the required libraries and the supported files which are discussed in earlier steps.
The sample folder structure is as follows:
Under the conf folder,
Note: Place the Service Layer build artifacts that are downloaded from the Oracle Software Delivery Cloud in the externallibs> conf > zip directory.
Provide the ServiceLayer Security realm details in “realm.properties” file (externallibs/jmeter/)
From the copied location, execute the below command:
docker build format:
$ docker build -t <Image_Name>:<Image_Tag> --build-arg APP_DOMAIN_NAME="<Domain_Name>" --build-arg APP_VERSION="<Build Release Version>" .
docker build example:
$ docker build -t sl_wls:12.0.3.0 --build-arg APP_DOMAIN_NAME="sl_domain" --build-arg APP_VERSION="12.0.3.0"
This generates the Service Layer WebLogic image.
To start the containerized Service Layer application, run
docker run format:
$ docker run -itd --privileged -v /path/to/the/externallibs:/u01/oracle/externallibs --env-file /path/to/the/sl_env.dat --name <Container_Name> --hostname <Container_HostName> -p <AdminServer_External_Port>:<AdminServer_Container_Port> -p <MS_External_Port>:<MS_Container_Port> <Image_Name>:<Image_Tag> createServer.sh $DB_TYPE
docker run example:
For Oracle: docker run -itd --privileged -v /path/to/the/externallibs/:/u01/oracle/externallibs --env-file /home/sl_env.dat --name sl_wls --hostname slwlsadmin -p 8030:8030 -p 8031:8031 --sysctl net.ipv4.ip_local_port_range="1024 65000" sl_wls:12.0.3.0 createServer.sh ORACLE
For MSSQL: docker run -itd --privileged -v /path/to/the/externallibs/:/u01/oracle/externallibs --env-file /home/sl_env.dat --name sl_wls --hostname slwlsadmin -p 8030:8030 -p 8031:8031 --sysctl net.ipv4.ip_local_port_range="1024 65000" sl_wls:12.0.3.0 createServer.sh MSSQL
Make Sure you define the Database names as below only (Case Sensitive)
Oracle Database: ORACLE
SQL Database: MSSQL
Check docker logs:
$ docker logs -f sl_wls
Note: The "APP_DOMAIN_NAME" build argument from the "docker build ...." command and the "--hostname" flag from the "docker run" commands should be the same which you denoted in the sl_env.dat file.
Service Layer Admin Console Domain Structure
Deployments
OIPA Service Layer Documentation