bigbluebutton-Github/bigbluebutton-html5/imports/utils
Daniel Schreiber c46556e1f6 Allow BBB to run behind a proxy the avoid gUM permission queries per node
The idea is to run a loadbalancer node which maps each BBB node to a
path. That way each user gets only one gUM permission query for a
cluster. The loadbalancer node only serves the html5 client, each BBB
node will serve its own API and handle the websockets for freeswitch and
bbb-webrtc-sfu.

Configuring a cluster setup
===========================

* let bbb-lb.example.com be the loadbalancer node
* let bbb-01.eaxmple.com be a BBB node

Loadbalancer
------------

On the loadbalancer node add an nginx configuration similar to this one
for each BBB node:

```
location /bbb-01/html5client/ {
  proxy_pass https://bbb-01.example.com/bbb-01/html5client/;
  proxy_http_version 1.1;
  proxy_set_header Upgrade $http_upgrade;
  proxy_set_header Connection "Upgrade";
}

```

BBB Node
--------

On the BBB node add the following options to
`/etc/bigbluebutton/bbb-web.properties`:

```
defaultHTML5ClientUrl=https://bbb-lb.example.com/bbb-01/html5client/join
presentationBaseURL=https://bbb-01.example.com/bigbluebutton/presentation
accessControlAllowOrigin=https://bbb-lb.example.com
```

Add the following options to `/etc/bigbluebutton/bbb-html5.yml`:

```
public:
  app:
    basename: '/bbb-01/html5client'
    bbbWebBase: 'https://bbb-01.eaxmple.com/bigbluebutton'
    learningDashboardBase: 'https://bbb-01.eaxmple.com/learning-dashboard'
  media:
    stunTurnServersFetchAddress: 'https://bbb-01.eaxmple.com/bigbluebutton/api/stuns'
    sip_ws_host: 'bbb-01.eaxmple.com'
  presentation:
    uploadEndpoint: 'https://bbb-01.eaxmple.com/bigbluebutton/presentation/upload'
```

Create the following unit file overrides:

* `/etc/systemd/system/bbb-html5-frontend@.service.d/cluster.conf`
* `/etc/systemd/system/bbb-html5-backend@.service.d/cluster.conf`

with the following content:

```
[Service]
Environment=ROOT_URL=https://127.0.0.1/bbb-01/html5client
```

Change the nginx `$bbb_loadbalancer_node` variable to the name of the
load balancer node in `/etc/bigbluebutton/nginx/loadbalancer.nginx` to
allow CORS requests:

```
set $bbb_loadbalancer_node https://bbb-lb.example.com
```

Prepend the mount point of bbb-html5 in all location sections except
from the `location @html5client` section in
`/etc/bigbluebutton/nginx/bbb-html5.nginx`

```
location @html5client {
    ...
}
location /bbb-01/html5client/locales {
    ...
}
```
2021-11-20 22:13:47 +01:00
..
browserInfo.js move browser info to helper + remove unused libs 2021-04-01 08:14:24 -03:00
caseInsensitiveReducer.js Make typed poll responses grouping case insensitive 2021-03-23 06:30:37 +00:00
deviceInfo.js move browser info to helper + remove unused libs 2021-04-01 08:14:24 -03:00
dom-utils.js Merge branch 'v2.4.x-release' of https://github.com/bigbluebutton/bigbluebutton into bbb-wcag-01 2021-09-08 11:26:08 +00:00
fetchStunTurnServers.js Allow BBB to run behind a proxy the avoid gUM permission queries per node 2021-11-20 22:13:47 +01:00
hexInt.js Moved hex_to_int and int_to_hex functions to imports/utils 2017-09-21 16:52:43 -07:00
humanizeSeconds.js solve error in nav-bar component 2017-10-23 14:26:56 -02:00
ios-webview-audio-polyfills.js Merge branch 'master' of https://github.com/bigbluebutton/bigbluebutton into 2.2-add-create-br-to-manage-user-menu 2019-01-21 17:02:18 +00:00
keyCodes.js Added event listener to change slides with Page Up and Page Down 2019-09-18 14:12:05 -03:00
lineEndings.js PR review fixes 2017-09-06 12:36:52 -07:00
logoutRouteHandler.js Added allowDefaultLogoutUrl config to optionally ignore non-custom logoutUrl 2020-10-08 05:15:05 -04:00
media-stream-utils.js fix(webcams): handle Firefox video stream cleanup edge case 2021-07-05 16:26:24 +00:00
mediaElementPlayRetry.js Improve log message for screenshare/listen only/autoplay and harden media play with retries 2019-09-06 18:58:22 +00:00
mimeTypes.js Linter auto fix 2017-06-02 19:25:02 +00:00
regex-weburl.js PR review fixes 2017-09-06 12:36:52 -07:00
sdpUtils.js fix(audio): mic not working when skipCheck=true 2021-07-06 10:27:48 -03:00
slideCalcUtils.js pan/zoom and cursor refactor for better performance 2019-07-25 15:55:25 -07:00
stats.js refactor(connection status): remove legacy monitor 2021-06-13 14:02:46 -03:00
statuses.js fix reported bugs / impliment suggested changes 2018-07-11 20:08:22 +00:00
string-utils.js update virtual background image tooltip text 2021-08-30 00:45:31 +00:00