blindsidenetworks / scalelite

Scalable load balancer for BigBlueButton.
GNU Affero General Public License v3.0
470 stars 247 forks source link

Waiting user is not pushed to conference when conference room is opened #667

Closed Uffi64 closed 2 years ago

Uffi64 commented 3 years ago

My Installation

Versions

Portalserver Docker-Container

Here you can find a grafical overview: pictured overview

The whole installation works well and is in use. Balancing by scalelite, BBB-Sessions, screensharing, turnserver, breakout-rooms, chats - works everything as a charm.

The situation If an invited user clicks his link when conference hasn't started he finds himself in the waiting room.

Expected behaviour When the conference room is opened the user should be pushed automatically into the confernece.

Problem The waiting user waits eternally to be forwarded. The only way for him to join the conference is to click the invitation link once again.

As far as I know the following configuration of scalelite-nginx is responsible here:

location ~ ^/(b$|b/) {
  proxy_pass          http://172.23.0.3:80;
  proxy_set_header    Host              $host;
  proxy_set_header    X-Forwarded-For   $proxy_add_x_forwarded_for;
  proxy_set_header    X-Forwarded-Proto $scheme;
  proxy_http_version  1.1;
}

location /bigbluebutton/api {
  proxy_pass          http://scalelite-api:3000;
  proxy_set_header    Host              $host;
  proxy_set_header    X-Forwarded-For   $proxy_add_x_forwarded_for;
  proxy_set_header    X-Forwarded-Proto $scheme;
  proxy_http_version  1.1;
}

location /b/cable {
  proxy_pass          http://172.23.0.3:80;
  proxy_set_header    Host              $host;
  proxy_set_header    X-Forwarded-For   $proxy_add_x_forwarded_for;
  proxy_set_header    X-Forwarded-Proto $scheme;
  proxy_set_header    Upgrade           $http_upgrade;
  proxy_set_header    Connection        "Upgrade";
  proxy_http_version  1.1;
  proxy_read_timeout  6h;
  proxy_send_timeout  6h;
  client_body_timeout 6h;
  send_timeout        6h;
}

I tried the following variants already but without any success. [1] X-Forwarded-Proto removed

location /b/cable {
  proxy_pass          http://172.23.0.3:80;
  proxy_set_header    Host              $host;
  proxy_set_header    X-Forwarded-For   $proxy_add_x_forwarded_for;
  proxy_set_header    Upgrade           $http_upgrade;
  proxy_set_header    Connection        "Upgrade";
  proxy_http_version  1.1;
  proxy_read_timeout  6h;
  proxy_send_timeout  6h;
  client_body_timeout 6h;
  send_timeout        6h;
}

[2] location modified

location ~ ^/b/cable$ {
  proxy_pass          http://172.23.0.3:80;
  proxy_set_header    Host              $host;
  proxy_set_header    X-Forwarded-For   $proxy_add_x_forwarded_for;
  proxy_set_header    X-Forwarded-Proto $scheme;
  proxy_set_header    Upgrade           $http_upgrade;
  proxy_set_header    Connection        "Upgrade";
  proxy_set_header    X-Forwarded-Ssl on;
  proxy_http_version  1.1;
  proxy_read_timeout  6h;
  proxy_send_timeout  6h;
  client_body_timeout 6h;
  send_timeout        6h;
}

[3] X-Forwardes-Ssl added

location /b/cable {
  proxy_pass          http://172.23.0.3:80;
  proxy_set_header    Host              $host;
  proxy_set_header    X-Forwarded-For   $proxy_add_x_forwarded_for;
  proxy_set_header    X-Forwarded-Proto $scheme;
  proxy_set_header    Upgrade           $http_upgrade;
  proxy_set_header    Connection        "Upgrade";
  proxy_set_header    X-Forwarded-Ssl on;
  proxy_http_version  1.1;
  proxy_read_timeout  6h;
  proxy_send_timeout  6h;
  client_body_timeout 6h;
  send_timeout        6h;
}

My greenlight .env - file

SECRET_KEY_BASE=<--- my secret key base --->
BIGBLUEBUTTON_ENDPOINT=https://my.domain.de/bigbluebutton/api/
BIGBLUEBUTTON_SECRET=<--- my scalelite bigbluebutton secret --->
SAFE_HOSTS=my.domain.de
ALLOW_GREENLIGHT_ACCOUNTS=true
SMTP_SERVER=my.mailserver.de
SMTP_PORT=587
SMTP_DOMAIN=domain.de
SMTP_USERNAME=smtpuser@domain.de
SMTP_PASSWORD=smtpuserpassword
SMTP_AUTH=plain
SMTP_STARTTLS_AUTO=true
SMTP_SENDER=me@domain.de
SMTP_TEST_RECIPIENT=test@domain.de
RELATIVE_URL_ROOT=/b
ROOM_FEATURES=mute-on-join,require-moderator-approval,anyone-can-start,all-join-moderator,recording
PAGINATION_NUMBER=25
NUMBER_OF_ROWS=25
MAINTENANCE_MODE=false
HELP_URL=https://docs.bigbluebutton.org/greenlight/gl-overview.html
ENABLE_SSL=true
DB_ADAPTER=postgresql
DB_HOST=db
DB_PORT=5432
DB_NAME=greenlight_production
DB_USERNAME=postgres
DB_PASSWORD=secret-db-password
CABLE_ADAPTER=postgresql
DEFAULT_REGISTRATION=open
WEB_CONCURRENCY=3

my greenlight docker-compose.yaml

version: '3'
networks:
  mygreenlight:
    ipam:
      config:
        - subnet: 172.23.0.0/16
services:
  app:
    entrypoint: [bin/start]
    image: custom-greenlight
    container_name: greenlight-v2
    env_file: .env
    restart: unless-stopped
    ports:
      - 127.0.0.1:5000:80
    networks:
      mygreenlight:
        ipv4_address: 172.23.0.3
    volumes:
      - ./log:/usr/src/app/log
      - ./storage:/usr/src/app/storage
    links:
      - db
  db:
    image: postgres:9.5
    restart: unless-stopped
    ports:
      - 127.0.0.1:5432:5432
    networks:
      mygreenlight:
        ipv4_address: 172.23.0.4
    volumes:
      - ./db/production:/var/lib/postgresql/data
    environment:
      - POSTGRES_DB=postgres
      - POSTGRES_USER=postgres
      - POSTGRES_PASSWORD=secret-db-password

On 2 other installations without scalelite where greenlight is on the same server as bbb things are working well.

Any hint to resolve this issue would be highly appreciated. Thanks to all.

git-lama commented 3 years ago

@Uffi64 haven't tried this setup so dont really know much. Maybe you can try posting this query in the GL forum.

Uffi64 commented 3 years ago

@amalrails Thanks for the answer. I try it at the greenlighters.