Deploying the on-premises gateway on Docker containers
Before you begin
- If you are a Helix subscriber, review the system requirements and obtain the container images and utility files.
- If you are using BMC Helix IT Operations Management on-premises and you want to enable authentication for the on-premises gateway, register the OAuth client. For more information, see set up authentication for the on-premises gateway .
Task 1: To deploy the on-premises gateway on Docker containers if you are a Helix subscriber
- Go to the server where you want to deploy the on-premises gateway.
- Copy the following files that you obtained to a temporary directory, for example, /<IIGateway_INSTALL_DIR>:
- Container images: bmc-hii-docker-images-<buildNumber>.tgz
- Utility file: hii-bmc-<buildNumber>.zip
- Disable SELinux:
- Open the /etc/selinux/config file with a text editor.
Set SELINUX to disabled.
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
# enforcing - SELinux security policy is enforced.
# permissive - SELinux prints warnings instead of enforcing.
# disabled - No SELinux policy is loaded.
SELINUX=disabled
# SELINUXTYPE= can take one of these two values:
# targeted - Targeted processes are protected,
# mls - Multi Level Security protection.
SELINUXTYPE=targeted
Reboot the server:
/sbin/reboot nowDisable firewalld:
systemctl disable firewalldSet the HOSTNAME variable to the fully-qualified domain name of the server where you are installing the on-premises gateway if not set already, as shown in the following example:
echo "export HOSTNAME=hostA.mycompany.com" >> ~/.bash_profile
source ~/.bash_profileLoad the container images:
docker load --input /<IIGateway_INSTALL_DIR>/bmc-hii-docker-images-<buildNumber>.tgzNavigate to the / <IIGateway_INSTALL_DIR> directory and extract the utility file, hii-bmc-<buildNumber>.zip:
unzip hii-bmc-<buildNumber>.zipChange permissions on the /<IIGateway_INSTALL_DIR>/hii/logs directory:
chmod 777 /<IIGateway_INSTALL_DIR>/hii/logsIf you encounter any issues, see To troubleshoot SSL issues to resolve them.
- Depending on whether you want to enable or disable the authentication for the on-premises gateway after the deployment, perform one of the following steps :
- To deploy the on-premises gateway for which authentication is enabled, perform the following steps:
- Navigate to the /<IIGateway_INSTALL_DIR>/hii/scripts directory.
Run the gateway_deployment.sh script:
./gateway_deployment.sh- Enter docker when prompted for the deployment method.
- Enter y to deploy the on-premises gateway.
- Enter the following information:
Access key and access secret key: Access key and secret key required to access the BMC Helix applications.
For instructions about how to generate the access key and secret key, see Setting up access keys for programmatic access.- Tenant Id: BMC Helix tenant ID.
Copy the tenant ID from the access key (key:<access key>::<secret key>,tenant id: <tenant ID>). - Tenant URL: BMC Helix tenant URL.
- Host name: Fully-qualified domain name of the server where you want to deploy the on-premises gateway.
After you provide all the credentials, the on-premises gateway is deployed. Also, the cred.json, external.config, and nginx.config configuration files are backed up in the /<userHome>/iig_auth directory.
- To deploy the on-premises gateway for which authentication is disabled, perform the following steps:
- Navigate to the /<IIGateway_INSTALL_DIR>/hii/scripts directory.
Run the gateway_deployment.sh script:
./gateway_deployment.sh- Enter docker when prompted for the deployment method.
- Enter n to start deploying the on-premises gateway.
- To deploy the on-premises gateway for which authentication is enabled, perform the following steps:
- Configure the BMC Helix destination to which you want to send data collected by BMC Helix Intelligent Integrations:
Create a file with the following contents and name it ade-default-destination-min.json:
[
{
"entityKind": "Destination",
"configWithSchema": {
"config": {
"connection": {
"proxyUsername": "",
"proxyPassword": "",
"accessSecretKey": "CHANGEME",
"allowUnsignedCertificate": false,
"logResponses": false,
"pipeLiningLimit": 1,
"proxyHost": "",
"logRequests": false,
"timeout": {
"unit": "MINUTES",
"value": 15
},
"proxyPort": 8888,
"maxResponseSize": 1000000,
"usesHttps": true,
"accessKey": "CHANGEME",
"port": 443,
"minConnections": 0,
"tenantId": "CHANGEME",
"connectingTimeout": {
"unit": "SECONDS",
"value": 30
},
"host": "CHANGEME - BMC Helix tenant host name - for example: swp-2021-1840-disceks1.abc.com",
"poolTimeout": {
"unit": "MINUTES",
"value": 30
},
"maxOpenRequests": 1024,
"maxConnections": 5,
"maxRedirects": 5,
"usesProxy": false
},
"poolTimeout": {
"unit": "MINUTES",
"value": 30
}
}
},
"instanceName": "BMC",
"tenantId": "287c466d-7467-4e72-9e52-8357b4a27eaf",
"typeName": "BmcDestination",
"id": "CHANGEME - GENERATE NEW UUID using https://www.uuidgenerator.net/version4 e.g. 2643e089-18a8-4b0d-a58a-c022926812e0 MUST BE UNIQUE in a stack",
"moduleId": "bmc"
}
]- Enter the values of the following parameters in the file:
- proxyUsername: User name for the proxy.
- proxyPassword: Password for the proxy.
- proxyPort: Proxy port number.
- proxyHost: Host name of the proxy.
- usesProxy: Whether proxy should be used for communication. Set its value to true or false depending on whether proxy should be used.
- Replace the CHANGEME value of the following parameters with the generated values:
accessKeyand accessSecretKey: Access key and secret key required to access the BMC Helix applications.
For instructions about how to generate the access key and secret key, see Setting up access keys for programmatic access.
- tenantId(first occurrence only): BMC Helix t enant ID.
Copy the tenant ID from the access key (key:<access key>::<secret key>,tenant id:<tenant ID>) that you generated earlier and replace the CHANGEME occurrences with the copied tenant ID. - host: BMC Helix tenant host name.
For example, if the tenant URL is https://swp-2021-1840-disceks1.abc.com , replace CHANGEME with swp-2021-1840-disceks1.abc.com. - id: Universally unique identifier (UUID).
Access https://www.uuidgenerator.net/version4 to generate UUID.
Access the BMC Helix Intelligent Integrations UI by using the following URL:
https://<hostName>:443/swpui
<hostName> is the fully-qualified domain name of the server where the on-premises gateway is deployed.
For example, https://swp-2021-1840-disceks1.abc.com:443/swpui.Import the ade-default-destination-min.json file by using the Backup/Restore option to create the destination .
For more information, see Backing-up-and-restoring-connector-configurations.- Edit the destination connection details:
- On the CONNECTORS tab, click Configure Mediator
on the DESTINATIONS panel.
- Replace the existing values in the Access Key and Access Secret Key fields with the values that you have copied in the ade-default-destination-min.json file in step 11.c.
- Click Validate to validate the connection.
- Click Save & Close.
- On the CONNECTORS tab, click Configure Mediator
- If you are using SSL certificates, import them into the on-premises gateway.
Task 1: To deploy the on-premises gateway on Docker containers if you are using BMC Helix IT Operations Management on premises
- Go to the server where you want to deploy the on-premises gateway.
- Copy the following files that you obtained to a temporary directory, for example, /<IIGateway_INSTALL_DIR>:
- Container images: bmc-hii-docker-images-<buildNumber>.tgz
- Utility file: hii-bmc-<buildNumber>.zip
- Disable SELinux:
- Open the /etc/selinux/config file with a text editor.
Set SELINUX to disabled.
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
# enforcing - SELinux security policy is enforced.
# permissive - SELinux prints warnings instead of enforcing.
# disabled - No SELinux policy is loaded.
SELINUX=disabled
# SELINUXTYPE= can take one of these two values:
# targeted - Targeted processes are protected,
# mls - Multi Level Security protection.
SELINUXTYPE=targeted
Reboot the server:
/sbin/reboot nowDisable firewalld:
systemctl disable firewalldSet the HOSTNAME variable to the fully-qualified domain name of the server where you are installing the on-premises gateway if not set already, as shown in the following example:
echo "export HOSTNAME=hostA.mycompany.com" >> ~/.bash_profile
source ~/.bash_profileLoad the container images:
docker load --input /<IIGateway_INSTALL_DIR>/bmc-hii-docker-images-<buildNumber>.tgzNavigate to the /<IIGateway_INSTALL_DIR> directory and extract the utility file, hii-bmc-<buildNumber>.zip:
unzip hii-bmc-<buildNumber>.zipChange permissions on the /<IIGateway_INSTALL_DIR>/hii/logs directory:
chmod 777 /<IIGateway_INSTALL_DIR>/hii/logsIf you encounter any issues, see To troubleshoot SSL issues to resolve them.
- Perform the following steps to deploy the on-premises gateway for which authentication is enabled after deployment:
- Perform the following steps to update the BMC Helix SSO configuration for Auth Proxy:
- Navigate to the <IIGATEWAY_INSTALL_DIR>/hii/conf/authproxy directory and open the external.conf file with a text editor.
- Update the file:
- Search for the rsso_external_url and rsso_internal_url parameters and replace {RSSO_URL} with the OpenID Connect Issuer URL.
- Search for the client_id parameter and replace {RSSO_CLIENT_ID} with the Client ID that you saved in a file while registering the OAuth client.
- Search for the client_secret parameter and replace {RSSO_CLIENT_SECRET} with the Client Secret that you saved in a file while registering the OAuth client.
- Locate the proxies section, and replace {TENANT_URL} with the BMC Helix tenant URL. For example, https://swp-2021-1840-disceks1.abc.com .
- Save the file.
- Perform the following steps to update the neo.feature.flags.auth-enabled parameter:
- Navigate to the /<IIGateway_INSTALL_DIR>/hii/conf directory.
- Open the swp.conf file with a text editor.
- Set the value of the neo.feature.flags.auth-enabled parameter to true.
- Save the file.
Start the docker-compose service:
docker compose up -d- Go to step 13 to configure the BMC Helix destination.
- Perform the following steps to update the BMC Helix SSO configuration for Auth Proxy:
- Perform the following steps to deploy the on-premises gateway for which authentication is disabled after deployment:
- Navigate to the /<IIGateway_INSTALL_DIR>/hii/scripts directory.
Run the gateway_deployment.sh script:
./gateway_deployment.sh- Enter docker when prompted for the deployment method.
- Enter n to start deploying the on-premises gateway.
- Go to step 13 to configure the BMC Helix destination.
- Configure the BMC Helix destination to which you want to send data collected by BMC Helix Intelligent Integrations:
Create a file with the following contents and name it ade-default-destination-min.json:
[
{
"entityKind": "Destination",
"configWithSchema": {
"config": {
"connection": {
"proxyUsername": "",
"proxyPassword": "",
"accessSecretKey": "CHANGEME",
"allowUnsignedCertificate": false,
"logResponses": false,
"pipeLiningLimit": 1,
"proxyHost": "",
"logRequests": false,
"timeout": {
"unit": "MINUTES",
"value": 15
},
"proxyPort": 8888,
"maxResponseSize": 1000000,
"usesHttps": true,
"accessKey": "CHANGEME",
"port": 443,
"minConnections": 0,
"tenantId": "CHANGEME",
"connectingTimeout": {
"unit": "SECONDS",
"value": 30
},
"host": "CHANGEME - BMC Helix tenant host name - for example: swp-2021-1840-disceks1.abc.com",
"poolTimeout": {
"unit": "MINUTES",
"value": 30
},
"maxOpenRequests": 1024,
"maxConnections": 5,
"maxRedirects": 5,
"usesProxy": false
},
"poolTimeout": {
"unit": "MINUTES",
"value": 30
}
}
},
"instanceName": "BMC",
"tenantId": "287c466d-7467-4e72-9e52-8357b4a27eaf",
"typeName": "BmcDestination",
"id": "CHANGEME - GENERATE NEW UUID using https://www.uuidgenerator.net/version4 e.g. 2643e089-18a8-4b0d-a58a-c022926812e0 MUST BE UNIQUE in a stack",
"moduleId": "bmc"
}
]- Enter the values of the following parameters in the file:
- proxyUsername: User name for the proxy.
- proxyPassword: Password for the proxy.
- proxyPort: Proxy port number.
- proxyHost: Host name of the proxy.
- usesProxy: Whether proxy should be used for communication. Set its value to true or false depending on whether proxy should be used.
- Replace the CHANGEME value of the following parameters with the generated values:
accessKeyand accessSecretKey: Access key and secret key required to access the BMC Helix applications.
For instructions about how to generate the access key and secret key, see Setting up access keys for programmatic access.- tenantId(first occurrence only): BMC Helix t enant ID.
Copy the tenant ID from the access key (key:<access key>::<secret key>,tenant id:<tenant ID>) that you generated earlier and replace the CHANGEME occurrences with the copied tenant ID. - host: BMC Helix tenant host name.
For example, if the tenant URL is https://swp-2021-1840-disceks1.abc.com , replace CHANGEME with swp-2021-1840-disceks1.abc.com. - id: Universally unique identifier (UUID).
Access https://www.uuidgenerator.net/version4 to generate UUID.
Access the BMC Helix Intelligent Integrations UI by using the following URL:
https://<hostName>:443/swpui
<hostName> is the fully-qualified domain name of the server where the on-premises gateway is deployed.
For example, https://swp-2021-1840-disceks1.abc.com:443/swpui .Import the ade-default-destination-min.json file by using the Backup/Restore option to create the destination .
For more information, see Backing-up-and-restoring-connector-configurations.- Edit the destination connection details:
- On the CONNECTORS tab, click Configure Mediator
on the DESTINATIONS panel.
- Replace the existing values in the Access Key and Access Secret Key fields with the values that you have copied in the ade-default-destination-min.json file in step 11.c.
- Click Validate to validate the connection.
- Click Save & Close.
- On the CONNECTORS tab, click Configure Mediator
- If you are using SSL certificates, import them into the on-premises gateway.
Task 2: To import SSL certificates into the on-premises gateway
- Obtain the SSL certificates from the BMC Helix platform deployment which the on-premises gateway is part of and save them in the <IIGateway_INSTALL_DIR>hii/conf directory.
Copy the cacerts file present in the swp-mediator container at /opt/java/lib/security to the /<IIGateway_INSTALL_DIR>/hii/conf/certs directory by using the following command:
docker cp swp-mediator:/opt/java/lib/security/cacerts /<IIGateway_INSTALL_DIR>hii/conf/certs/cacerts_mediator(If authentication is enabled for the on-premises gateway) Copy the cacerts file present in the swp-authproxy container at /opt/java/openjdk/lib/security to the /<IIGateway_INSTALL_DIR>/hii/conf/certs directory by using the following command:
docker cp swp-authproxy:/opt/java/openjdk/lib/security/cacerts /<IIGateway_INSTALL_DIR>hii/conf/certs/cacerts_authproxy- Navigate to the /<IIGateway_INSTALL_DIR>/hii/conf/certs directory.
- Import the certificates into the copied file by using the keytool utility.
Import the certificates into the cacerts_mediator file by using the following command:
keytool -importcert -file <certificate_name> -keystore cacerts_mediator -alias <alias_name>Replace the certificate_name with the certificate name that you obtained from the BMC Helix platform deployment.
(If authentication is enabled for the on-premises gateway) Import the certificates into the cacerts_authproxy file by using the following command:
keytool -importcert -file <certificate_name> -keystore cacerts_authproxy -alias <alias_name>Replace the certificate_name with the certificate name that you obtained from the BMC Helix platform deployment.
- Open the /<IIGateway_INSTALL_DIR>/hii/docker-compose.yaml file with a text editor:
- Update the file:
Search for the mediator section and add the following line to the volumes section:
- ./conf/certs/cacerts_mediator:/opt/java/lib/security/cacerts(If authentication is enabled for the on-premises gateway) Search for the authproxy section and add the following line to the volumes section:
- ./conf/certs/cacerts_authproxy:/opt/java/openjdk/lib/security/cacerts
- Save and close the docker-compose.yaml file.
Restart the docker service by using the following commands:
docker compose down
docker compose up -d
To troubleshoot SSL issues
Problem | Possible root cause | Possible resolution |
---|---|---|
Containers restart due to the permission-denied errors. | Containers don't have permission to read the mounted directory. |
|
You are not able to access the URL with the host name. | Firewall is blocking the connection. | Disable the firewall. |
The swp-nginx container is not starting. | The nginx.conf file contains an invalid configuration. | Check the swp-nginx container logs. Sometimes, missing semi-colon(;) at the end of the line causes an issue. |
Where to go from here
After you deploy the on-premises gateway, perform the following tasks:
- ( Optional ) If you want to ensure high availability of the on-premises gateway instances in case of any failure, see Configuring-the-on-premises-gateway-for-high-availability.
- Configure connections with the required third-party products to collect data.