Configuration
To configure ApiOmat Analytics, you need to edit the /frontend/express/config.js file in your analytics folder (e.g. /opt/aomanalytics/..).
For the connectivity to the ApiOmat Dashboard, you have to set its URL in the "aomDashboardUrl" parameter (at the bottom of the file). This address defines the backlink (to ApiOmat Dashboard) within the Analytics Dashboard.
In this file you can also configure the MongoDB for analytics, the default-settings are (only if needed):
host:
"localhost"
,
db:
"countly"
,
port: 27017,
max_pool_size: 10,
Since Analytics (Countly) comes with two js-servers (one for frontend and the other one for the api), you also need to configure the mongo-settings in the "/api/config.js"-file for the api-server.
If you are using MongoDB with a specific user, you also have to configure the MongoDB settings in both analytics config-files:
-
/frontend/express/config.js
-
/api/config.js
mongodb: {
host:
"YOUR_HOST_HERE"
,
db:
"countly"
,
port:
27017
,
max_pool_size:
10
,
username:
"YOUR_DATABASE_USER"
,
password:
"YOUR_PASSWORD"
,
dbOptions:{
//db options
native_parser:
true
,
authSource:
"admin"
// database name for auth
},
...
After modifying the configuration, you have to stop countly with:
sudo
countly stop
and run the initialization script in /opt/aomanalytics/bin as root user:
sudo
bash
aom_init.sh
ApiOmat Configuration
After the installation, you can set the property "isAnalyticsEnabled" to true in the yambas.conf/apiomat.yaml to enable the ApiOmat-Analytics feature for your installation.
Additionally, you have to set the properties "analyticsHostInternal" - as internal host target of the installation, and "analyticsHostPublic" - as external reachable address of the analytics instance.
The following snippet shows the three lines to add to your config:
isAnalyticsEnabled=
true
analyticsHostInternal=http:
//localhost/analytics
analyticsHostPublic=http:
//www.yourdomain.yourhost.tld/analytics
analytics:
enabled:
true
hosts:
internal: http:
//localhost/analytics
public
: http:
//www.yourdomain.yourhost.tld/analytics
!! You also need to add "Analytics" to the default Modules in apiomat.yaml / yambas.conf - since 2.5 the apiomat.yaml doesn't need the "enabled: true" line!!
You now need to restart the Tomcat.
Activate Analytics
A restart of the Tomcat server will not initialize your analytics instance anymore (since 3.0.1).
You have to log in into the Dashboard via the SuperAdmin account, go to the configuration page and click the "Activate Analytics" button .
This will initialize the connection between Analytics and Yambas.
After configuring analytics, you need to know how to manage the nodejs servers.