How to Install Exalate for ServiceNow on Docker?

    You can host Exalate for Servicenow on your own server. To do so, you need to install Exalate on Docker.

    Check out Docker documentation for details on how to install Docker.

    How to Install Exalate for ServiceNow?

    1. Create or download the docker-compose.yml

    The below example docker-compose.yml file can be used to install Exalate for ServiceNow.

    1. Create a directory that would hold the docker-compose file:

      cd ~
      mkdir exalate-snownode
    2. Create or download a docker-compose.yml file.

      Click docker-compose.yml to download the file.

      The file should contain the following information:

      We recommend using the latest version of Exalate for ServiceNow. It can be found in the Release History.

      Enter the latest version in the image tag. For example, in image: idalko/snownode:5.1.3, the version of Exalate for ServiceNow is 5.1.3 .

      version: '2'
      
      services:
        database:
          restart: unless-stopped
          image: postgres:9.4
          volumes:
            - ./persist/db:/var/lib/postgresql/data
            - ./createdb.sh:/docker-entrypoint-initdb.d/init-user-db.sh
          environment:
            - POSTGRES_PASSWORD=changeme
            - DB_NAME=snownode
            - DB_USER=idalko
            - DB_PASS=idalko
          networks:
            - dbnet
      
        snownode:
          restart: unless-stopped
          ports:
            - 9000:9000
      
          #
      	# Change the image tag to the required version
          # Check Release History on docs.exalate.com for an overview
          #
          image: idalko/snownode:5.1.3
          depends_on:
            - database #wait for postgres to be started, not for ready
          volumes:
            - ./persist/home:/opt/snownode/data
          environment:
            # Add your enviroment settings here
            - SNOWNODE_PG_HOST=database
            - SNOWNODE_PG_DB=snownode
            - SNOWNODE_PG_USER=idalko
            - SNOWNODE_PG_PWD=idalko
            - SNOWNODE_PORT=9000
          networks:
            - dbnet
            - default
      
      networks:
        dbnet:
          driver: bridge
        default:
          driver: bridge
      
      

    2. Ensure that a correct database is set up using a createdb.sh

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

    #!/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******"
    
    

    or download: createdb.sh

    3. Set environment variables if necessary

    Below you can find the environment variables used for the app container. All of them are optional, and in the given example, we've overridden snownode_PG_DB, snownode_PG_USER, and snownode_PG_PWD just to show how to pass different credentials to the Exalate application.


    Full list of environment variables
    Variable nameExampleDescription
    SNOWNODE_PG_HOSTSNOWNODE_PG_HOST=databasetells Exalate where is the Postgres database to connect is hosted
    SNOWNODE_PG_DBSNOWNODE_PG_DB=exalatetells Exalate what is the Postgres database name for the Exalate application
    SNOWNODE_PG_USERSNOWNODE_PG_USER=exalatetells the Exalate application what is the Postgres database user name for the Exalate application to perform queries with
    SNOWNODE_PG_PWDSNOWNODE_PG_PWD=secrettells the Exalate application what is the Postgres database user's password for the Exalate application to perform queries with
    SNOWNODE_PORTSNOWNODE_PORT=80

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

        ports:
          - 9000:9000

    should also be changed to

        ports:
          - 80:80


    SMTP_HOST_NAMESMTP_HOST_NAME=smtp.gmail.comThe hostname of the SMTP server used to send error notifications
    SMTP_PORTSMTP_PORT=587Port (also check the TLS setting)
    SMTP_FROMSMTP_FROM=my.name@gmail.comEmail that is used to send error notifications
    SMTP_LOGINSMTP_LOGIN=my.nameLogin to the SMTP service
    SMTP_PASSSMTP_PASS=secret

    Password to the SMTP service

    SMTP_TLSSMTP_TLS=trueCan be set to false, but then the snownode_SMTP_PORT should be set to the port, that accepts non-SSL and non-TLS connections
    POLL_PAIR_TIMEPOLL_PAIR_TIME=90 tells Exalate to set the polling frequency to 90 seconds for PAIR events
    POLL_UPDATE_TIMEPOLL_UPDATE_TIME=90 tells Exalate to set the polling frequency to 90 seconds for UPDATE events

    Connecting to Postgres 10 or Higher

    For unencrypted connections from Exalate to a Postgres version 10 or higher, you need to disable gssEncMode with the following setting:

    # exalate is the name of the database on the postgres instance
    #
    SNOWNODE_PG_DB=exalate?gssEncMode=disable 

    Using a Proxy for Outgoing Connections

    Whenever Exalate needs to use a proxy to establish outgoing connections, use the following parameters in the environment (naming should be obvious):

    • PROXY_HTTP_HOST
    • PROXY_HTTP_PORT
    • PROXY_HTTPS_HOST
    • PROXY_HTTPS_PORT

    Deprecated

    The following fields are not valid anymore starting from version 5.0.28 onward:

    Full list of environment variables
    Variable nameExampleDescription
    snownode_SMTP_HOST_NAMEsnownode_SMTP_HOST_NAME=smtp.gmail.comis used to send email notifications about errors blocking synchronization
    snownode_SMTP_PORTsnownode_SMTP_PORT=587is used to send email notifications about errors blocking synchronization
    snownode_SMTP_FROMsnownode_SMTP_FROM=my.name@gmail.comis used to send email notifications about errors blocking synchronization
    snownode_SMTP_USERsnownode_SMTP_USER=my.nameis used to send email notifications about errors blocking synchronization
    snownode_SMTP_PASSsnownode_SMTP_PASS=secretis used to send email notifications about errors blocking synchronization
    snownode_SMTP_TLSsnownode_SMTP_TLS=trueis used to send email notifications about errors blocking synchronization. Can be set to false, but then the snownode_SMTP_PORT should be set to the port, that accepts non-SSL and non-TLS connections

    4. Start the application


    cd ~/exalate-snownode
    docker-compose up -d


    After starting Exalate for ServiceNow you will need to verify your instance. Check out Verify your Exalate for ServiceNow for more information.

    Troubleshooting

    Problems during the installation of the Exalate server for Snownode

    If you have problems during the installation of the Exalate app for Servicenow you can find logs describing possible problems inside /tmp.

    The name for the file is generated randomly and automatically by the OS, but you can find the file by the creation date.

    Problems while running the Exalate server for Snownode

    Logs will be generated under the directory: /opt/snownode/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.