This project provides a web frontend for retained topics served by the HiveMQ Retained Message Query Plugin.
The topic browser can be configured either with env variables or with a config.json file, which needs to be served beside the sources. Provide Username and password, if the broker is used with the HiveMQ file RBAC extension.
WS_BROKER_URI="<ws_broker_uri>"
HTTP_BROKER_URI="<http_broker_uri>"
USERNAME="<username>"
PASSWORD="<password>"
{
"wsBrokerUri": "<ws_broker_uri>",
"httpBrokerUri": "<http_broker_uri>",
"username": "<username>",
"password": "<password>"
}
Copy config.json.template
into public/config.json
and edit properties or use env variables.
For production build test npm run start
, copy config.json.template
into dist/config.json
and edit properties or use env variables.
The service can be deployed to Dokku using the Node.js buildpack.
- add dokku server as remote
git remote add <name> dokku@<server>:topic-browser
- on first deployment
ssh dokku@<server> apps:create topic-browser
- set configuration
ssh dokku@<server> config:set topic-browser HTTP_BROKER_URI=<http_broker_uri> WS_BROKER_URI=<ws_broker_uri>
- deploy to server
git push <name> master
- Build
npm run build
- Configure
Add a dist/config.json
file with properties as in config.json.template
- Serve
Serve the dist
folder.