Ansible Role: IBM HTTP Server (IHS)
Relevant source files
The following files were used as context for generating this wiki page:
The ihs role is responsible for the automated installation, patching, and configuration of IBM HTTP Server (IHS) within the SPM Middleware ecosystem. It handles the deployment of the base server, the WebSphere Web Server Plug-ins (PLG), and the WebSphere Customization Toolbox (WCT), primarily targeting environments required for Cúram Social Program Management.
This role operates by leveraging the IBM Installation Manager (IIM) to manage software packages. It supports both major versions 8.5 and 9.0, providing specific task flows for base installations and fix pack upgrades for each version. The role ensures that the web server is not only installed but also configured with necessary SSL certificates, administrative users, and performance tuning drop-ins.
Sources: roles/ihs/README.md:3-8, roles/ihs/tasks/main.yml:11-20
Installation Architecture
The installation process follows a modular approach based on the version specified in the ihs_version variable. The role dynamically includes task files for either Version 8.5 or Version 9.0 depending on the ihs_pid metadata.
Installation Workflow
The workflow involves preparing local or remote repositories, extracting installation media, and using the iim_package module to execute the installation through IBM Installation Manager.
Sources: roles/ihs/tasks/main.yml:2-27
Components Installed
| Component | Description | Default Path |
|---|---|---|
| IBM HTTP Server (IHS) | The core web server based on Apache HTTP Server. | /opt/IBM/HTTPServer |
| WebSphere Plug-ins (PLG) | Enables IHS to communicate with WebSphere Application Servers. | /opt/IBM/WebSphere/Plugins |
| Customization Toolbox (WCT) | Tools for configuring the plug-ins and web server definitions. | /opt/IBM/WebSphere/Toolbox |
Sources: roles/ihs/README.md:12-14, roles/ihs/tasks/v90_base_install.yml:78-109
Configuration and Security
Post-installation, the role executes configure.yml to secure the instance and set up the operational environment.
Security and Authentication
The role manages administrative access by creating an admin.passwd file using the htpasswd utility. It also handles the generation of self-signed SSL certificates for secure communication.
Sources: roles/ihs/tasks/configure.yml:2-55
Configuration Management
The role uses a "drop-in" configuration pattern, creating a conf.d directory and including it in the main httpd.conf file. Specific configuration files rendered include:
custom_ihs_perf.conf: For performance tuning.custom_ssl.conf: For SSL termination settings.custom_staticcontent.conf: For managing static assets.
Sources: roles/ihs/tasks/configure.yml:13-26
Role Variables
The following variables control the deployment behavior and versioning of the IHS installation.
| Variable | Default Value | Description |
|---|---|---|
ihs_version | 9.0.5.22 | The target version of IHS to install. |
ihs_install_path | /opt/IBM/HTTPServer | Installation directory for the web server. |
ihs_admin_user | wasadmin | Username for the IHS administrative console. |
ihs_admin_pass | wasadmin | Password for admin user (should be changed after install). |
download_url | (Optional) | URL to fetch installers if not provided locally on the controller. |
ihs_config_type | local_distributed | Type of configuration for the IHS instance. |
Sources: roles/ihs/README.md:11-39
Fix Pack Management
The role supports upgrading existing installations to specific fix pack levels. For version 9.0, this involves building a list of fix pack repositories and using iim_package to update the components.
Implementation Details: v90 Base Install
The Version 9.0 installation (v90_base_install.yml) specifically includes the IBM Java SDK as a required dependency for the components.
- name: Install IHS
iim_package:
iim_path: "{{ iim_install_path }}"
product_id:
- "com.ibm.websphere.IHS.{{ ihs_pid.split('_') | first }}"
- com.ibm.java.jdk.v8
path: "{{ ihs_install_path }}"
repo: "{{ repo_list }}"
properties:
"user.ihs.httpPort": 80
state: present
Sources: roles/ihs/tasks/v90_base_install.yml:78-90
This task ensures that both the IHS product and the Java 8 JDK are present in the target installation path, setting the default HTTP port to 80. Similar tasks are defined for the Plug-in (PLG) and Customization Toolbox (WCT).
Sources: roles/ihs/tasks/v90_base_install.yml:92-109
Summary
The IHS Ansible role provides a comprehensive automation suite for IBM HTTP Server management. By integrating with IBM Installation Manager and handling complex configuration tasks like SSL generation and Plug-in Customization Tool (PCT) execution, it ensures consistent and repeatable middleware deployments for SPM environments.