Design Hub install guide

Design Hub is a NodeJS based application for hypothesis management and molecule design. It includes an HTTP and WebSocket server to serve multiple clients running the embedded web application. Design Hub releases are made available using docker images, and require a PostgreSQL database as well as JChem Microservices on the backend.

Installation is only required for the server, clients access the web server through the configured host and port.

Server requirements

  • Windows Server 2016 or newer, or Ubuntu 16.04.3 LTS, RHEL/CentOS 7.0 or newer with

  • docker-ce 18.03 or newer

  • Min 1GB free RAM

  • 500MB free space

  • PostgreSQL 10.1 or newer

  • JChem Microservices 20.8 LTS or newer

  • live internet connection to https://hub.chemaxon.com/ during installation

Client requirements

  • Latest Chrome, Firefox ETS or newer frequent release, Edge 18 or newer, Safari 11 or newer

Installing Docker

You need docker-ce 18.03 or newer version to run Design Hub's docker images. Download the installer from https://www.docker.com/ and follow the installation wizard for your operating system. Linux users may install from their mainline repositories if available. To verify a successful installation, open the terminal and type:

user:~$ docker -v
Docker version 19.03.8, build afacb8b

Installing Docker-compose

To simplify network configuration and provide a configuration file suitable for version control, it is recommended that on local docker engines, you use docker-compose and yml files to manage Design Hub. Download the installer from https://docs.docker.com/compose/install/ and follow the install wizard for your operating system. To verify a successful installation, open the terminal and type:

user:~$ docker-compose -v
docker-compose version 1.25.5, build 8a1c60f6

Installing Design Hub

Now you need to authenticate your docker engine with the ChemAxon download site. The instructions on the download page provide you with the API key used to access the repository. This is required the first time only. If your firewall requires whitelisting hub.chemaxon.com using its IP address, please reach out to us on our support addresses, so we can send you IP addresses and notify you should that need changes.

user:~$ echo <encrypted API key> | \
docker login -u <email address> --password-stdin hub.chemaxon.com

Choose an application directory where you want to manage configuration details. Once there, you can install the application with:

user:~$ mkdir app
user:~$ cd app/
user:~/app$ docker pull hub.chemaxon.com/cxn-docker-release/chemaxon/dh:latest

This will download and install the latest version of the application in the app directory. You can find the full list of recently added features and changes in the History of changes document.

Upgrading to a new version

You can upgrade Design Hub with the install command, which will fetch the latest version. To install a specific version, append its version number to the package name with the following syntax: dh:20.13.0

user:~/app$ docker pull hub.chemaxon.com/cxn-docker-release/chemaxon/dh:latest

This will check and download any fresh Design Hub images, but leave any configuration, persistence intact.

Configuration

This application requires a configuration file to be passed as a command line argument. The configuration file holds all the key settings regarding database connectivity, networking, security, persistence, plugins and more.

The minimum configuration requires port and license attributes to be specified, but a more general sample of the options is below. Note that some values point to files or other services. These should be changed to match your environment - of course you can store your ChemAxon license files or Design Hub plugins anywhere. See below in the spreadsheet for your full list of options:

{
 "databaseHost": "localhost",
"databasePort": 5432,
"databaseUser": "root",
"databasePassword": "CHANGETHIS",
"databaseName": "designhub",
"jchemMicroServices": "http://localhost:8070/",
 "port": 8888,
 "license": ["./marvin4js-license.cxl", "./mlive-license.cxl"],
 "secretKey": "CHANGETHIS",
 "authentication": {
  "internal": {
"type": "local",
"label": "Testing domain",
"accounts": [{
"username": "demo",
"password": "demo"
}]
}
}
}

In the Configuration Guide you can find a detailed description for options and further customization instructions.

Volumes

volume location

description

/config

This folder stores the configuration file of Design Hub, and the entrypoint script loads config.json file from this location. It is recommended that you mount your config.json and files it may refer to (e.g. certificates) using this folder.

/license

This folder stores ChemAxon license files required by Design Hub and the default configuration loads all *.cxl files from this location. Path to this folder is configured by the ML_LICENSE environment variable, but it is recommended that it's not overwritten.

/services

This folder stores NodeJS plugins, and the default configuration loads all *.js files (corresponding to the support plugin types) from this location. Path to this folder is configured by the ML_SERVICES_DIRECTORY environment variable, but it is recommended that it's not overwritten.

Usage:

user:~$ docker run --rm -it \
-p 8888:8888 \
-v `pwd`/license:/license \
-v `pwd`/config.json:/config/config.json \
-v `pwd`/services:/services \
hub.chemaxon.com/cxn-docker-release/chemaxon/dh:latest

Starting Design Hub

Once a basic config file is available, you can start the server in foreground mode with:

user:~/app$ docker run --rm -it -p 8888:8888 -v `pwd`/config.json:/config/config.json -v `pwd`/license:/license hub.chemaxon.com/cxn-docker-release/chemaxon/dh:latest

When the application is ready to use, it prints Listening on http://localhost:8888/.

To stop a running instance, simply press Ctrl+C.

Given the IP or hostname of your server and the port set in the configuration, you may now distribute the web interface link to the users of the application.

Design Hub behind a proxy

Design Hub uses a persistent websocket connection between each client and the server for messaging. If you deploy the application behind a proxy, you need to make sure the proxy doesn't interfere with websockets. In case of nginx, you should review the websocket module’s configuration options.