Ansible playbook to provision a WebLogic Fusion Middleware Domain on RHEL 7

Chris VezalisAnsible, DEVOPS, Fusion Middleware, WebLogic

An Ansible Playbook for installing and configuring a WebLogic 12c server with Oracle Fusion Middleware 12.1.3 software in Redhat Linux 7 (RHEL/CentOS/Oracle Linux) system. This playbook is for version 12.1.3 of WebLogic and Fusion Middleware Infrastructure software.

You can download the code here:

Prerequisites for running the playbook

– Configure your environment variables in infra-vars.yml. This file contains variables like the user and group we will use to install and run the software, the base directory for installation and configuration, the name of JDK installer file, the name of Fusion Middleware installer file and other similar settings.

– Set your passwords in secrets.yml. This file contains all the passwords needed for playbook. The password for Oracle operating system user needs to be encrypted. Use mkpasswd for create it.

– A running Oracle Database for hosting the repositories and sys credentials for generating the repositories, are required. A playbook for database coming soon 🙂

– A running RHEL 7 system with minimal installation and network configured. (IP address, hostname etc). For testing you can use the Vagrant configuration.

– Download the latest Java 7 jdk, put the file in roles/linux-jdk/files and configure infra-vars.yml with installer file name.

– Download the 12.1.3 Oracle Fusion Middleware installer from Oracle support, put it in roles/fmw-software/files and configure infra-vars.yml with installer file name.

The playbook includes the following Ansible Roles:

linux-wls: Configures the linux system with required packages, kernel settings etc.
linux-jdk: Installs Oracle JDK 7.
fmw-software: Installs Oracle Fusion Middleware Infrastructure software.
fmw-domain: Creates a Domain with Fusion Middleware support (Enterprise Manager, JRF, etc).
fmw-managed-server: Creates a managed server for host applications.

Run the playbook
To test the playbook you can download Vagrant and Virtual Box and then run from within the download folder the following code:

$ vagrant plugin install vagrant-hostmanager
$ vagrant up
$ ansible-playbook weblogic-fmw-domain.yml

When the playbook finishes execution you can connect to the weblogic server using wls12c1.private:7001/console.

Chris Vezalis