Confluence has been updated to version 6.15.9

Introduction

You need to install the Docker. Check docker documentation for more details.


To install Exalate for HP ALM/QC

Create a docker-compose 

Create a directory which would hold the docker-compose file: 

cd ~
mkdir exalate-hp-qc

Create docker-compose.yml file in it: 

cd exalate-hp-qc
touch docker-compose.yml
cat > docker-compose.yml << 'EOF'
version: '2'

services:
  database:
    restart: always
    image: postgres:9.4
    volumes:
      - voldatabase:/var/lib/postgresql/data
      - ./createdb.sh:/docker-entrypoint-initdb.d/init-user-db.sh
    environment:
      - DB_NAME=hpqcnode
      - DB_USER=idalko
      - DB_PASS=idalko
    networks:
      - database

  hpqcnode:
    restart: always
    ports:
      - 9000:9000
    image: idalko/hpqcnode:latest
    depends_on:
      - database #wait for postgres to be started, not for ready
    volumes:
      - volhpqcnode:/opt/hpqcnode/data
    environment:
      - HPQCNODE_PG_DB=hpqcnode
      - HPQCNODE_PG_USER=idalko
      - HPQCNODE_PG_PWD=idalko
    networks:
      - database
      - default

volumes:
  voldatabase:
  volhpqcnode:

networks:
  database:
    driver: bridge
  default:
    driver: bridge
EOF

Please note the environment variables used for hpqcnode container. All of them are optional, and in the given example, we've overridden HPQCNODE_PG_DB, HPQCNODE_PG_USER and HPQCNODE_PG_PWD just to explicitly how can different credentials be passed to the Exalate application.

Here's the full list of environment variables

Variable nameDefault valueExampleDescription
HPQCNODE_PG_HOSTHPQCNODE_PG_HOST=databaseHPQCNODE_PG_HOST=localhosttells Exalate where is the postgres database to connect to hosted
HPQCNODE_PG_DBHPQCNODE_PG_DB=hpqcnodeHPQCNODE_PG_DB=exalatetells Exalate what is the postgres database name for the exalate application
HPQCNODE_PG_USERHPQCNODE_PG_USER=idalkoHPQCNODE_PG_USER=exalatetells Exalate what is the postgres database user name for the exalate application to perform queries with
HPQCNODE_PG_PWDHPQCNODE_PG_PWD=idalkoHPQCNODE_PG_PWD=secrettells Exalate what is the postgres database user's password for Exalate to perform queries with
HPQCNODE_PORTHPQCNODE_PORT=9000HPQCNODE_PORT=80

tells what which is the port to start Exalate on. Note that this is the port within the exalatehpqc_hpqcnode_1 container, thus if this variable is changed (for example to 80), the

    ports:
      - 9000:9000

should also be changed to

    ports:
      - 80:80


HPQCNODE_SMTP_HOST_NAMEHPQCNODE_SMTP_HOST_NAME=mail.server.comHPQCNODE_SMTP_HOST_NAME=smtp.gmail.comis used to send email notifications about errors blocking synchronization
HPQCNODE_SMTP_PORTHPQCNODE_SMTP_PORT=465HPQCNODE_SMTP_PORT=587is used to send email notifications about errors blocking synchronization
HPQCNODE_SMTP_FROMHPQCNODE_SMTP_FROM=admin@admin.comHPQCNODE_SMTP_FROM=my.name@gmail.comis used to send email notifications about errors blocking synchronization
HPQCNODE_SMTP_USERHPQCNODE_SMTP_USER=adminHPQCNODE_SMTP_USER=my.nameis used to send email notifications about errors blocking synchronization
HPQCNODE_SMTP_PASSHPQCNODE_SMTP_PASS=1234567HPQCNODE_SMTP_PASS=secretis used to send email notifications about errors blocking synchronization
HPQCNODE_SMTP_TLSHPQCNODE_SMTP_TLS=trueHPQCNODE_SMTP_TLS=trueis used to send email notifications about errors blocking synchronization. Can be set to false, but then the HPQCNODE_SMTP_PORT should be set to the port, that accepts non-SSL and non-TLS connections



create "createdb.sh" (referenced from docker-compose.yml):

touch createdb.sh
cat > createdb.sh << 'EOCREATEDB'
#!/bin/bash

TEST=`psql -U postgres <<-EOSQL
   SELECT 1 FROM pg_database WHERE datname='$DB_NAME';
EOSQL`

echo "******CREATING DOCKER DATABASE******"
if [[ $TEST == "1" ]]; then
    # database exists
    # $? is 0
    exit 0
else
psql -U postgres <<-EOSQL
   CREATE ROLE $DB_USER WITH LOGIN ENCRYPTED PASSWORD '${DB_PASS}' SUPERUSER;
EOSQL

psql -U postgres <<-EOSQL
   CREATE DATABASE $DB_NAME WITH OWNER $DB_USER ENCODING 'UNICODE' LC_COLLATE 'C' LC_CTYPE 'C' TEMPLATE template0;
EOSQL

psql -U postgres <<-EOSQL
   GRANT ALL PRIVILEGES ON DATABASE $DB_NAME TO $DB_USER;
EOSQL
fi

echo ""
echo "******DOCKER DATABASE CREATED******"
EOCREATEDB


Ensure that the volumes are included in your backup strategy:

  • voldatabase
  • volhpqcnode

Start the application

cd ~/exalate-hp-qc
docker-compose up -d

Check how to manage the application on docker

Run queries to the application's database

cd ~/exalate-hp-qc
docker exec -it exalatehpqc_database_1 bash
su postgres
psql -A $DB_NAME

One can find all the tables using psql's \dt+ command: 

\dt+

All the postgres SQL queries are permitted

To exit the application's DB:

\q
# \q exits the psql 
exit
# exits the postgres user session
exit
# exits the exalatehpqc_database_1 bash session

Inspect the application's filesystem

cd ~/exalate-hp-qc
docker exec -it exalatehpqc_hpqcnode_1 bash

Remove the application

cd ~/exalate-hp-qc
docker-compose rm

Remove the application data

Danger zone - do this only if you wish to lose all the synchronization information, including the current synchronizations enqueued to be performed and synchronization status.

Be sure that remote side (you exalate issues with) knows that you're stopping synchronization and are ready to handle synchronization errors.

cd ~/exalate-hp-qc
# docker volume ls | grep exalatehpqc_vol |  awk '{ print $2 }' | xargs docker volume rm
docker volume rm exalatehpqc_voldatabase
docker volume rm exalatehpqc_volhpqcnode


Troubleshooting

Problems during the installation of Exalate for HP ALM/QC

If you have problems during installation of the Exalate app for HP ALM/QC, you can find logs describing possible problem inside /tmp. The name for this file is generated randomly automatically by the OS but you should be able to find the file based on the creation date.

Problems while running Exalate for HP ALM/QC

Logs will be generated under the directory: /opt/hpqcnode/data/logs. Refer to these logs to get more information about possible problems and communicate with our support if you need any assistance.


Support

Check our Support options if necessary.