Installation

This guide describes the Quickstart which is part of the project repo.

The installation starts all required services using this docker-compose-file:

qs-async-apim-www

a nginx service as a single point of entry, see nginx.conf for exposed services

qs-async-apim-admin-portal

the admin and developer portal web server

qs-async-apim-server

the portal server

qs-async-apim-server-mongodb

the portal database

qs-async-apim-connector

the connector

qs-async-apim-connector-mongodb

the connector database

See also

Prerequisites

The quickstart requires the following components:

  • docker

  • docker-compose

Tested with:

  • MacOs: Docker Desktop

    • Docker version 20.10.17, build 100c70

    • docker-compose version 1.29.2, build 5becea4c

  • ubuntu-18.04:

    • Docker version 20.10.17+azure-1, build 100c70180fde3601def79a59cc3e996aa553c9b9

    • docker-compose version 1.29.2, build 5becea4c

Note

CentOS: use docker-ce instead of docker to get the latest version(s).

Setup

Note

To use the quickstart configuration, clone the github repository:

git clone https://github.com/solace-iot-team/async-apim.git
cd async-apim/quickstart

At start-up, the APIM Server creates a root user based on these environment variables, which can be found in the start.sh. All other variables are set directly in the docker.compose.yml file.

Note

Change the default root user & password in start.sh.

# Note: change these
export APIM_SERVER_ROOT_USER="root.admin@async-apim-quickstart.com"
export APIM_SERVER_ROOT_USER_PWD="admin123!"

Start, Stop, Update

Change to the Quickstart directory.

Start:

./start.sh

Stop:

./stop.sh

Update:

If you want to start with clean APIM Server & Connector databases, run:

./stop.sh
./clean.sh

Now start the system again:

./start.sh

Connect

By default, the docker.compose.yml creates an NGINX container serving as a reverse proxy on port 5000.

Use the following URL in your browser: http://{ip-address}:5000.

Additional exposed ports are:

  • 5001 - APIM Connector

  • 5002 - APIM Server

Test Exposed Routes

Test the following URLs in your browser:

  • Route to the APIM Server: http://{ip-address}:5000/apim-server

    • You should see a response in your browser similar to this:

    {"appId":"qs-async-apim-server","errorId":"pathNotFound","description":"path does not exist","meta":{"path":"/apim-server"}}
    
  • Route to the APIM Server API: http://{ip-address}:5000/apim-server/v1/apsMonitor/apsStatus

    • You should see a response in your browser similar to this:

    {"isReady":true,"timestamp":1656929362213}
    

Details

The following figure shows the set-up of the containers:

../_images/async-apim.quickstart.containers.png

Figure 1: Quickstart Docker Compose Container Setup

Browser connections:

Note that the portal app uses the APIM Server as a proxy for the APIM Connector with the following URL: /apim-server/v1/connectorProxy/v1.

../_images/async-apim.quickstart.connect.png

Figure 2: Quickstart Browser Connections