This app allows you to view registered devices, with user/extension labels (including hotdesk extensions they are logged into), and you can view their call status in real time.
The device's current extension appears in the lower right of the device object. Normally, it will be red. If a device has hotdesk users on it, the normal extension turns grey and the hotdesk extension[s] is displayed in pulsing blue above the normal extension.
The "Lite" version is completely free and open source (released under the GPLv3). I would love for you to let me know if you are using it! Also give me a Github star if you find it useful. :-)
The "Pro" version does everything the Lite version does, but it also allows you to answer/pickup calls, park calls, transfer calls, and shows parked calls in the parkinglot (and allows you to retrieve them with a click). Contact me via my site https://ruhnet.co for purchase information.
Clone the repository to your Monster UI apps directory (often /var/www/html/monster-ui/apps, but may be different on your system). Then you may register the app on KAZOO with a sup command (with your specific Crossbar API location):
cd /var/www/html/monster-ui/apps
git clone https://github.com/ruhnet/monster-ui-switchboard-lite switchboard
sup crossbar_maintenance init_app '/var/www/html/monster-ui/apps/switchboard' \
'http://mycrossbarapi.tld:8000/v2'
The default Blackhole websockets port is 5555, but it is unencrypted. I strongly recommend that you proxy it with TLS on another port. I use Nginx for this, (see sample Nginx config below), but mainly because I'm using Nginx as the webserver for Monster and some other things on the system. HAproxy works perfectly for this also.
In your Monster-UI directory, edit the js/config.js
file to include the following line in the api
block:
socket: 'wss://mykazooserver.tld:5443',
Or if you are just running on a test server (or you want to live dangerously), and you are not proxying websockets with TLS:
socket: 'ws://mykazooserver.tld:5555',
NOTE: If your MonsterUI is served over HTTPS, then browsers will block connections to unencrypted websockets. So you must proxy with TLS if you also serve MonsterUI over HTTPS. If you access Monster via unencrypted HTTP, then you can get by with using unencrypted plain websockets also.
Your api
block in js/config.js
should then look something like this:
api: {
provisioner: 'https://p.ruhnet.co/', //you'll have this line if you use a provisioner
socket: 'wss://mykazooserver:5443', //websockets URL
default: 'https://mykazooserver:8443/v2/' //API URL
},
Also, make sure that the Blackhole port you are using is open in your firewall:
firewall-cmd --permanent --add-port=5443/tcp
firewall-cmd --reload
(This is in addition to existing HAProxy config for CouchDB etc.) Note that HAProxy requires the key, cert, and CA to be bundled into a single PEM file.
listen kazoo-websockets
bind *:5443 ssl crt /etc/ssl/yourcertificate.pem
default_backend kapps-blackhole
backend kapps-blackhole
balance source
option forwardfor
option http-server-close
option forceclose
no option httpclose
server kz1.z100-blackhole 1.2.3.4:5555 check
server kz2.z100-blackhole 2.3.4.5:5555 check
server kz1.z200-blackhole 123.123.123.234:5555 check backup
upstream blackhole {
server kazooapps1.mydomain.tld:5555;
server kazooapps2.mydomain.tld:5555;
server kazooapps1_zone2.mydomain.tld:5555 backup;
}
server {
listen 5443 ssl http2;
server_name mykazooserver.tld;
location / {
proxy_pass http://blackhole;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
}
ssl_certificate /etc/ssl/mykazooserver.tld/fullchain.crt;
ssl_certificate_key /etc/ssl/mykazooserver.tld/privkey.key;
ssl_trusted_certificate /etc/ssl/mykazooserver.tld/fullchain.pem;
ssl_dhparam /etc/ssl/private/dh_2048.pem;
ssl_session_cache shared:SSL:20m;
ssl_session_timeout 4h;
ssl_session_tickets on;
ssl_protocols TLSv1.3 TLSv1.2;
ssl_prefer_server_ciphers on;
add_header Strict-Transport-Security max-age=15768000;
ssl_stapling on;
ssl_stapling_verify on;
}