This section discusses how Oracle WebLogic Server 12.1.3 can be configured to run inside a Docker container. Docker is a Linux-based container technology that enables you to quickly create lightweight clustered and non-clustered WebLogic Server domain configurations on a single host OS or virtual machines, for either development or production environments.
Docker is a platform that enables users to build, package, ship and run distributed applications. Docker users package up their applications, and any dependent libraries or files, into a Docker image.
Docker images are portable artifacts that can be distributed across Linux environments. Images that have been distributed can be used to instantiate containers where applications can run in isolation from other applications running in other containers on the same host operating system.
As part of the certification, Oracle has released Dockerfiles and supporting scripts on GitHub to build images for WebLogic Server. These images are built as an extension of existing Oracle Linux images. To help you create and run WebLogic Server Docker images, the Dockerfiles and supporting scripts posted on GitHub can be used as examples to help you get started. For more information, see About the Dockerfiles and Scripts on GitHub.
To support building your Docker images, Oracle has certified using WebLogic Server 12.1.3 with various combinations of JDK versions, Oracle Linux and RedHat Linux OS versions, Kernel versions, and Docker versions. For detailed certification information about supported WebLogic Server Docker images, see
You can also create your own WebLogic Server Docker images. To facilitate this process, Oracle has posted Dockerfiles and scripts on GitHub as examples that can help you to get started.
These are the prerequisites to build custom WebLogic Server Docker images:
Supported Oracle Linux or Red Hat Linux base image
Dockerfiles and scripts from GitHub
Oracle WebLogic Server 12c (12.1.3) generic installer or Developer installer
Corresponding supported JDK
To facilitate the building and running of WebLogic Server Docker images, Oracle has posted Dockerfiles and supporting scripts on GitHub. Download the entire directory structure to build your Oracle WebLogic Server images and start your containers. To access these files, go to
These Dockerfiles and scripts enable you to extend your image and create clustered and non-clustered Oracle WebLogic Server domain configurations, including both development and production running on a single host operating system or on VMs. Please note that the Dockerfiles and scripts on Github are only intended to be samples for you to write your own Dockerfiles and build your WebLogic Server images.
Note:Oracle has certified WebLogic Server with the RedHat Linux image; however, the Dockerfiles on GitHub are written to extend only the Oracle Linux image. If you want to create a WebLogic Server image and extend a RedHat Linux image, then you must modify these Dockerfiles to do so.
Each server running in the resulting domain configurations runs in its Docker container, and is capable of communicating as required with other servers. Other configurations and approaches are possible, as described in Building WebLogic Server Images on Docker.
There are two types of Dockerfiles available on GitHub for WebLogic Server 12c (12.1.3), located under the
Dockerfile.developer – builds a WebLogic Server "developer" install image.
Dockerfile.generic – builds a WebLogic Server "generic" domain image.
WebLogic Server Install Image Dockerfile
The Dockerfile to create an WebLogic Server install image performs the following functions:
Extends the Oracle Linux base image.
Installs the JDK.
Installs WebLogic Server using either the Generic or Developer installer (depending on which Dockerfile you choose).
After creating your WebLogic Server install images, you can extend them to have a base WebLogic Server domain configured.
WebLogic Server Domain Image Dockerfile
The Dockerfile to create an WebLogic Server domain image performs the following functions:
Extends the WebLogic Server install image.
Configure a WebLogic Server domain by calling WLST scripts. The domain has one Administration Server with a JMS server and a data source, and also enables JPA 2.1 and JAX-RS 2.0.
Figure 1-1 illustrates a WebLogic Server domain image.
Using the Oracle WebLogic Server domain image you can create two types of containers:
Administration server container with a single WebLogic Server Administration server, as shown in Figure 1-2.
Managed server container with a node manager, which adds itself as a machine to the Administration Server and a Managed Server, as shown in Figure 1-3.
The supported scripts aid in the creation of a WebLogic Server 12c (12.1.3) Docker image and serve as examples to extend the image with the configuration of a WebLogic Server domain. The scripts are located under the following subdirectories:
The scripts in Table 1-1 help in the creation of a WebLogic Server install image and the starting of WebLogic servers inside of a Docker container.
Table 1-1 Supported WebLogic Server Scripts for Docker on GitHub
|Script||What it does|
Builds the image using the WebLogic Server installation Dockerfile instructions.
Removes all ghost containers and all ghost images.
Removes all running containers.
WLST scripts to create a machine using the Managed Server container name.
WLST scripts to create a Managed Server.
Enables JPA 2.1 support.
WLST script configures a base domain with one Administration Server, JMS server, JSP, and data source.
Starts a Node Manager in the container and calls
Starts a Node Manager in the container and calls
Template to configure JAX-RS.
WebLogic Server uses a machine concept, which is an operational system with an agent, the Node Manager. This machine resource allows the Administration Server to create and assign Managed Servers to a domain and/or cluster, expand a domain and/or cluster, and to deploy applications and resources to the Managed Servers.
By using machines in containers, you can configure a Dynamic Cluster and easily scale up your cluster by starting new Managed Server containers. Using the WebLogic Server Scripting Tool (WLST), your cluster can quickly be scaled in and out. For more information about the Node Manager, see Administering Node Manager for Oracle WebLogic Server, and for more information about using WLST, refer to Oracle Fusion Middleware Oracle WebLogic Scripting Tool.
The Docker containers enable you to create clustered and non-clustered WebLogic Server domain configurations across a single Linux host. Each server in the domain runs in its own Docker container and is capable of communicating with other servers on the same host. It is important to note that Oracle does not support clustered WebLogic Servers across multiple hosts.
One topology is to configure a WebLogic Server cluster on Docker containers across a single host, as show in Figure 1-4.
The advantages of this topology are:
Suited for traditional WebLogic Server deployments (with a WebLogic domain and a cluster (or multiple clusters), and several servers in each cluster).
Easy to deploy containers from WebLogic domain images.
Easy to scale a cluster up or down.
Convenient for developers.
No need to install or configure anything on the host except for Docker binaries.
A recommended topology that is in line with the "Docker way" for configuring containerized applications and services, consists of a container designed to run only an WebLogic Administration Server that contains all resources, shared libraries, and deployments. The Docker image includes all domain resources pre-defined, applications, and shared libraries deployed up-front, and no Managed Servers or clusters configured, as shown in Figure 1-5.
The advantages of this topology are:
Uses the Docker "recommended" way for configuring containerized applications and services.
Containers are easily repeatable.
Each container is an instance of the same WebLogic domain.
The containers can all be on a single physical or virtual server Linux host as shown in Figure 1-5, or they can be on multiple physical or virtual server Linux hosts, as shown in Figure 1-6.
Another possible topology is a single Oracle WebLogic Server domain running on a single container on a single Linux host communicating with a WebLogic Server instance on a remote host and a database.
Figure 1-7 illustrates a single WebLogic Server domain in a Docker containers on a single host.