# BigBlueButton Web Conferencing

> Open source web conferencing for online learning with recordings and breakout rooms.

- Category: Message Queues & Brokers
- Difficulty: advanced
- Components: bigbluebutton, nginx, redis, mongodb, coturn
- Tags: bigbluebutton, video, education, webrtc, lms
- Source: https://docker.recipes/messaging/bigbluebutton-complete

## Overview

BigBlueButton is an open-source web conferencing platform specifically designed for online learning and educational environments. Originally developed at Carleton University in 2009, BigBlueButton has become the de facto standard for educational institutions requiring feature-rich virtual classrooms with screen sharing, interactive whiteboards, breakout rooms, and session recordings. Unlike generic video conferencing solutions, BigBlueButton focuses on pedagogical features that enhance remote learning experiences.

This deployment stack integrates BigBlueButton's multiple microservices with supporting infrastructure components to create a fully functional web conferencing platform. The bbb-web service handles the main application logic and API endpoints, while bbb-html5 provides the modern client interface using MongoDB for real-time data storage and Redis for session management and pub/sub messaging. FreeSWITCH manages voice communications, Kurento handles video streaming and WebRTC media processing, and NGINX serves as the reverse proxy to orchestrate traffic between these services.

Educational institutions, corporate training departments, and organizations requiring GDPR-compliant self-hosted video conferencing should consider this stack. The combination provides enterprise-grade features like recording management, user analytics, and integration capabilities with Learning Management Systems, while maintaining complete data sovereignty that cloud-hosted solutions cannot guarantee.

## Features

- Interactive whiteboard with multi-user drawing capabilities and shape recognition
- Automated session recordings with playback timeline and chapter markers
- Breakout room management with drag-and-drop participant assignment
- Screen sharing with presenter controls and annotation overlay
- Real-time chat with emoji reactions and private messaging
- Polling and quiz integration with instant result visualization
- WebRTC-based audio/video with automatic quality adaptation
- Learning Management System integration via standardized APIs

## Use cases

- Universities deploying virtual classrooms with recording capabilities for hybrid learning
- Corporate training departments requiring breakout room functionality for team exercises
- K-12 schools needing FERPA-compliant video conferencing with parental controls
- Government agencies requiring self-hosted conferencing for sensitive communications
- Healthcare organizations conducting telemedicine consultations with HIPAA compliance
- Non-profit organizations hosting community meetings with multilingual support
- Research institutions conducting remote collaboration with screen sharing and whiteboard tools

## Prerequisites

- Minimum 4GB RAM (8GB+ recommended) due to multiple BigBlueButton microservices
- External IP address configured for WebRTC connectivity through NAT/firewalls
- UDP port range 16384-32768 accessible for FreeSWITCH media streaming
- SSL certificate for HTTPS operation (required for WebRTC in modern browsers)
- TURN server credentials for participants behind restrictive firewalls
- Domain name or static IP for consistent API endpoint configuration

## docker-compose.yml

```yaml
services:
  bbb-web:
    image: bigbluebutton/bbb-web:latest
    ports:
      - "8080:8080"
    environment:
      - BBB_SECRET=${BBB_SECRET}
      - BBB_SERVER_URL=http://localhost
    volumes:
      - bbb_data:/var/bigbluebutton
    networks:
      - bbb_net

  bbb-html5:
    image: bigbluebutton/bbb-html5:latest
    environment:
      - MONGO_URL=mongodb://mongodb:27017/bbb
      - REDIS_HOST=redis
    depends_on:
      - mongodb
      - redis
    networks:
      - bbb_net

  bbb-freeswitch:
    image: bigbluebutton/bbb-freeswitch:latest
    environment:
      - EXTERNAL_IP=${EXTERNAL_IP}
    ports:
      - "16384-32768:16384-32768/udp"
    networks:
      - bbb_net

  bbb-kurento:
    image: bigbluebutton/bbb-kurento:latest
    environment:
      - TURN_URL=${TURN_URL}
      - TURN_USERNAME=${TURN_USER}
      - TURN_PASSWORD=${TURN_PASSWORD}
    networks:
      - bbb_net

  mongodb:
    image: mongo:4.4
    volumes:
      - mongodb_data:/data/db
    networks:
      - bbb_net

  redis:
    image: redis:7-alpine
    volumes:
      - redis_data:/data
    networks:
      - bbb_net

  coturn:
    image: coturn/coturn:latest
    ports:
      - "3478:3478"
      - "3478:3478/udp"
    environment:
      - TURN_USER=${TURN_USER}
      - TURN_PASSWORD=${TURN_PASSWORD}
    networks:
      - bbb_net

  nginx:
    image: nginx:alpine
    ports:
      - "80:80"
      - "443:443"
    volumes:
      - ./nginx.conf:/etc/nginx/nginx.conf:ro
    depends_on:
      - bbb-web
    networks:
      - bbb_net

volumes:
  bbb_data:
  mongodb_data:
  redis_data:

networks:
  bbb_net:
```

## .env

```bash
# BigBlueButton
BBB_SECRET=your_bbb_shared_secret_key
EXTERNAL_IP=your.external.ip
TURN_URL=turn:your.turn.server:3478
TURN_USER=turnuser
TURN_PASSWORD=secure_turn_password

# BBB at http://localhost
# API at http://localhost/bigbluebutton/api
```

## Usage notes

- BBB at http://localhost
- API endpoint at /bigbluebutton/api
- Designed for online learning
- Breakout rooms support
- Recording and playback

## Troubleshooting

- Audio/video connection failures: Verify TURN server credentials and ensure UDP port range 16384-32768 is not blocked by firewall
- MongoDB connection timeout errors: Increase MongoDB memory allocation and check network connectivity between bbb-html5 and mongodb services
- FreeSWITCH registration failures: Confirm EXTERNAL_IP environment variable matches your server's public IP address
- NGINX 502 Bad Gateway errors: Check that bbb-web service is fully started before NGINX attempts proxying (add health checks or startup delays)
- Recording playback failures: Verify bbb_data volume has sufficient disk space and proper write permissions for recording storage
- Kurento WebRTC negotiation errors: Ensure TURN_URL, TURN_USERNAME, and TURN_PASSWORD environment variables are correctly configured for NAT traversal

