IIG Automation version-2

Modified on Wed, 26 Feb at 3:02 PM

 Description

This document provides information about automating IIG installation.

Prerequisites:

  • Instance for IIG setup

  • Whitelist of N2N NAT IPs(QA: 23.20.165.255/32, PROD: 54.204.165.208/32)

  • FQDN, which connects to the Integration Gateway on HTTPS

  • Python 3.9 or higher

  • Docker 17.x or higher

  • SSL certificates(Chain cert and Private Key)


Info

pip3 is mandatory for running these scripts, ensure python 3.9 has a pip3 package manager


Info

A Docker module is also needed along with the Docker RPM package, use the below command to install the module

pip3 install docker


Supported Platforms for Python and Docker

Platform

Docker

Python

CentOS

Yes

Yes

Debian

Yes

Yes

Red Hat Enterprise Linux

Yes

Yes

Fedora

Yes

Yes

openSUSE

Yes

Yes

Amazon Linux

Yes

Yes

Oracle Linux

Yes

Yes



Note

This Setup does not support Microsoft Windows


Info

Ensure that the operating system platform meets all the required prerequisites

Downloading a tar file

  • Sign in to the Illuminate application(either QA or PROD) then select “New/Upgrade Installation” and choose the “Default Script” option.

image (254) (4).png

  • Once you click “Submit” button a tar will be available to download

image (256) (2).png

Setup Process

The IIG automation process is divided into THREE steps:

  • Installation process

    • In this step, the required Docker containers, dataport and nginx, will be installed.

  • SSL configuration process

    • SSL certificate configuration will be implemented at this stage.

  • Database configuration process

    • At this step, database configuration details will be added to establish a connection to the data source for the dataport.

Installation Process

  • Once you upload the tar file onto the server, untar the tar file using below command

tar -xvf iig-client.tar -C /opt

  • Go to the directory with the below command and run the install.py, this python service will create docker network and run the docker containers dataport and nginx

cd /opt/iig
./install.py
Note

If the file has insufficient execute permissions, configure the permissions chmod +x install.py

image-20241220-122434.png

  • Verify the docker containers and the docker network

image-20241220-123120.pngimage-20241220-123246.png

SSL Configuration Process

  • Run sslconfig.py python service, it will prompt you for a few mandatory details, please provide them

image-20241220-123440.png

  • This step is a NAT IP check where it will ask if the NAT IP is whitelisted. Provide 'Y' if it is whitelisted; otherwise, the script will stop at this point

image-20241219-094347.png

  • Select the specific IIG Setup environment. Please choose the environment number based on your requirement (e.g., 2)

image-20241219-094607.png

  • This setup is a port check where it will ask if port 443 is open in the firewall rules.

image-20241219-095052.png

  • In this step, you need to provide the Fully Qualified Domain Name (FQDN) that points to the IIG server. The script will create a data/user.json file under /opt/iig to store the FQDN

image-20241220-123856.png

  • The next section is about SSL certificates, where you need to enter the full path to the complete SSL certificate(chain cert) and the matching private key that are uploaded on the server. The script will also create a folder named ssl under /opt/iig to store the SSL files

image-20241219-101152.png

  • The SSL files and the Nginx configuration file will automatically uploaded into Nginx docker container

image-20241219-101335.png

  • At the end of this script, the /idp dataport service is triggered to ensure that the SSL configuration has been applied successfully

image-20241220-124052.png

Database Configuration Process

  • Run databaseconfig.py python service, it will prompt you for a database details, provide them according to the database provider

image-20241220-124143.png

  • In this section, the script checks if the IIG server can reach the database host using the provided database host and port. If the connection is not successful, the script will exit at this point

image-20241220-124335.png

  • In the Database Configuration section, the script will prompt you to select the database provider type. Choose the provider by selecting the corresponding number

  • After selecting the database provider type, the script will prompt you to enter the database information specific to the selected provider

Example: Oracle

image-20241219-142936.png

Example: MySQL

image-20241219-143119.png

  • In the next step, the script will prompt you to enter the authorization token from IlluminateApp. To obtain it, log in to the IlluminateApp UI, navigate to the 'Connections' tab, and add the DataPort URL

image-20241220-124804.pngimage-20241220-125225.png

  • After adding the DataPort URL, click on 'Add Database Provider' and enter the required details. Once you click the 'Save' button, the authorization token will be generated

image-20241219-144748.png

  • Copy the Authorization token and paste it on the server

image-20241219-145230.png

  • After you press Enter, the script will automatically generate a curl command based on the selected database provider. Verify the details and respond with 'yes' or 'no'

image-20241220-125356.png

  • The database properties will be added to the dataport, and the dataport container will restart automatically through the script

image-20241219-150234.png

  • At the end, the folders /opt/iig/ssl and /opt/iig/data are deleted, and the idp status is displayed. Finally, the script prompts you to confirm the deletion of the IIG setup Python scripts and the /opt/iig folder

image-20241220-125525.png

  • You can also check the idp status in the illuminateapp UI

image-20241220-125642.png

APPENDIX-1: Integration Gateway setup for PROD on the same QA host/server

If the client wants to set up a PROD integration gateway on the QA host, they need to follow these steps

  • Run the install.py script with the argument prod. This will create a Docker network named iig_prod, launch the Docker container dataportProd, and attach the Docker network to both nginx and dataportProd

./install.py prod

  • The script will ask for the fully qualified domain name attached to the server. Once entered, it will display the idp2 status

image-20250102-115720.pngimage-20250102-115403.png

  • Run the databaseconfig.py Python service with the argument prod, and it will prompt you for the database details. Provide them according to the database provider

./databaseconfig.py prod
Note

If no argument is provided the scripts will default to the QA setup

APPENDIX-2: Integration Gateway and Nginx Upgrade

If the client wants to upgrade integration gateway(dataport or dataportProd) and Nginx, they need to follow these steps

docker cp dataport:/usr/local/tomcat/webapps/idp/WEB-INF/classes/<yourdbfile>.properties /opt/
  • Run update.py with the argument dataport to update dataport to the latest version. The updated dataport will automatically attach to the existing Docker network, while the previous version will be renamed to dataport.bk and disconnect from the Docker network

./update.py dataport

image-20250129-114956.png

  • Run the following command to restore the database properties in the upgraded dataport

docker cp /opt/<yourdbfile>.properties dataport:/usr/local/tomcat/webapps/idp/WEB-INF/classes/
docker exec  --user root dataport chown n2ndataport:n2ndataport /usr/local/tomcat/webapps/idp/WEB-INF/classes/dbiig.properties
docker restart dataport
Note
To upgrade dataportProd hosted on the same server, replace the dataport argument with dataportProd and run the restore database properties commands
  • To upgrade NGINX, run update.py with the nginx argument. This will copy the SSL certificates and config files from the existing NGINX to the new NGINX Docker container and automatically attach it to the existing Docker network. If dataport and dataportProd are hosted on the same server, the new NGINX container will connect to both the Docker networks that dataport and dataportProd are connected to. The previous version of NGINX will be renamed to nginx.bk and disconnect from the Docker network

./update.py nginx

image-20250129-121153.png

 

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article