Skip to content

Ansible playbook collection to provision Weblogic 12c+ cluster

License

Notifications You must be signed in to change notification settings

sergey-gr/ansible-weblogic-cluster

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Weblogic Cluster provisioning

Repository contains everything to provision a Weblogic Cluster on any RedHat 7+ based system..


1. Requirements

System requirements:

  • 1 VM with minimums of 2 cpus and 4GB RAM (HDD size is on your preference) for AdminServer
  • 1 - ∞ VMs with minimum of 2 cpus and 8GB RAM each (HDD size is on your preference) for Managed Servers
  • static IPs on all VMs
  • supported linux OS: RedHat/CentOS 7/8, Oracle Linux 7/8, Rocky 8, AlmaLinux 8

Workstation requirements:

Additional requirements:

1.1. Proxy requirements

Access to following external resources are required:

  • Access to OS repository (yum/apt)
  • Access to Python packages (*.python.org, *.pypi.org, *.pythonhosted.org)
  • Access to Oracle Java and Middleware installer download (*.oracle.com)

2. Configuration

  • Create copy of inventory/default directory and name it after your environment, example: inventory/<environment>.
  • Edit your environment inventory.ini file by filling out environment servers configuration values.
  • Edit your environment all.yml file by filling out environment specific configuration values (also see 2.1 Installers).
  • Edit your environment all-vault.yml file by filling out environment specific secrets.

NOTE: Encrypt the all-vault.yaml file using ansible-vault encrypt inventory/<environment>/group_vars/all/all-vault.yml and providing secure password.

2.1 Installers configuration

NOTE: Instructions for downloading and configuring installers.

Download Linux x64 Compressed Archive and place tar.gz archive to:

./roles/jdk/files/jdk-8u371-linux-x64.tar.gz

Also set archive name (ex. jdk-8u371-linux-x64.tar.gz) as value for variable in your environments all.yml file.

jdk_installer_archive: 'jdk-8u371-linux-x64.tar.gz'

Download Generic Installer for Oracle WebLogic Server 12.2.1.4, extract archive and place generic jar installer to:

./roles/wls/files/fmw_12.2.1.4.0_wls_lite_generic.jar

Also set installer name (ex. fmw_12.2.1.4.0_wls_lite_generic.jar) as value for variable in your environments all.yml file.

fmw_installer: 'fmw_12.2.1.4.0_wls_lite_generic.jar'

3. Testing configuration

Before installation you can test connection to your VMs using check.yml playbook.

Simply run:

ansible-playbook -i inventory/<environment>/inventory.ini playbooks/check.yml --ask-vault-pass

Output should look like this:

NOTE: If playbook ran with no errors, then you are ready to begin installation.

...
TASK [debug] **********************************************************************
ok: [wl-admin] =>
  msg:
  - 'os_family: RedHat'
  - 'distribution: AlmaLinux'
  - 'major_version: 8'
ok: [wl-node-01] =>
  msg:
  - 'os_family: RedHat'
  - 'distribution: AlmaLinux'
  - 'major_version: 8'
ok: [wl-node-02] =>
  msg:
  - 'os_family: RedHat'
  - 'distribution: AlmaLinux'
  - 'major_version: 8'
...

4. Installation

Playbook to install and configure Weblogic cluster.

ansible-playbook -i inventory/<environment>/inventory.ini playbooks/setup.yml --ask-vault-pass

Will configure the cluster based on provided configuration in inventory files.

❗ Weblogic console URL after installation: http://<admin_host_ip>:{{ admin_server_port }}/console


5. Uninstall

Playbook to uninstall Weblogic cluster.

ansible-playbook -i inventory/<environment>/inventory.ini playbooks/reset.yml

Will uninstall the Weblogic cluster and reboot the machines.

6. Cluster maintanace tasks

Playbook to update some parts of Cluster or Domain configuration

ansible-playbook -i inventory/<environment>/inventory.ini playbooks/update.yml -t <tag>

Will update specific part of configuration.

Currently available tags:

Category File Path Tag Description
Update playbooks/update.yml ssl Will update Managed server SSL certificate and do SSL reset.