forked from extern/docker
Merge pull request #3 from alangecker/freeswitch-separation
Separate freeswitch into its own container
This commit is contained in:
commit
a4871a8c5b
@ -6,26 +6,33 @@ services:
|
||||
restart: unless-stopped
|
||||
depends_on:
|
||||
- redis
|
||||
environment:
|
||||
DOMAIN: ${DOMAIN}
|
||||
SHARED_SECRET: ${SHARED_SECRET}
|
||||
WELCOME_FOOTER: ${WELCOME_FOOTER}
|
||||
volumes:
|
||||
- bigbluebutton:/var/bigbluebutton
|
||||
networks:
|
||||
bbb-net:
|
||||
ipv4_address: 10.7.7.2
|
||||
|
||||
freeswitch:
|
||||
build: mod/freeswitch
|
||||
cap_add:
|
||||
- SYS_NICE # for realtime scheduling
|
||||
- SYS_ADMIN # for systemd
|
||||
- IPC_LOCK
|
||||
- NET_ADMIN
|
||||
- NET_RAW
|
||||
- NET_BROADCAST
|
||||
- SYS_NICE
|
||||
- SYS_RESOURCE
|
||||
environment:
|
||||
DOMAIN: ${DOMAIN}
|
||||
EXTERNAL_IP: ${EXTERNAL_IP}
|
||||
SHARED_SECRET: ${SHARED_SECRET}
|
||||
WELCOME_FOOTER: ${WELCOME_FOOTER}
|
||||
container: docker
|
||||
tmpfs:
|
||||
- /run
|
||||
- /run/lock
|
||||
- /tmp:exec,mode=777
|
||||
volumes:
|
||||
- bigbluebutton:/var/bigbluebutton
|
||||
- /sys/fs/cgroup:/sys/fs/cgroup:ro # for systemd
|
||||
- ./conf/sip_profiles:/opt/freeswitch/conf/sip_profiles/external
|
||||
- ./conf/dialplan_public:/opt/freeswitch/conf/dialplan/public_docker
|
||||
- ./conf/sip_profiles:/etc/freeswitch/sip_profiles/external
|
||||
- ./conf/dialplan_public:/etc/freeswitch/dialplan/public_docker
|
||||
network_mode: host
|
||||
|
||||
|
||||
nginx:
|
||||
image: nginx:1.17
|
||||
restart: unless-stopped
|
||||
|
@ -10,10 +10,9 @@ ENV DEBIAN_FRONTEND noninteractive
|
||||
ENV container docker
|
||||
ENV DOCKERIZE_VERSION v0.6.1
|
||||
|
||||
RUN apt-get update && apt-get install -y software-properties-common language-pack-en wget
|
||||
RUN apt-get update && apt-get install -y software-properties-common language-pack-en wget apt-utils
|
||||
RUN update-locale LANG=en_US.UTF-8
|
||||
RUN LC_CTYPE=C.UTF-8 add-apt-repository ppa:rmescandon/yq
|
||||
RUN apt-get install -y --no-install-recommends apt-utils
|
||||
|
||||
# install dockerize
|
||||
RUN wget https://github.com/jwilder/dockerize/releases/download/$DOCKERIZE_VERSION/dockerize-linux-amd64-$DOCKERIZE_VERSION.tar.gz \
|
||||
@ -24,13 +23,12 @@ RUN wget https://github.com/jwilder/dockerize/releases/download/$DOCKERIZE_VERSI
|
||||
# RUN apt-get install -y tcpdump telnet htop vim
|
||||
|
||||
# -- Install Dependencies
|
||||
RUN apt-get install -y systemd apt-transport-https equivs libreoffice haveged ttf-liberation net-tools
|
||||
RUN apt-get install -y supervisor apt-transport-https equivs libreoffice haveged ttf-liberation net-tools
|
||||
|
||||
# bbb repo & packages
|
||||
RUN LC_CTYPE=C.UTF-8 add-apt-repository ppa:bigbluebutton/support
|
||||
RUN sh -c 'wget https://ubuntu.bigbluebutton.org/repo/bigbluebutton.asc -O- | apt-key add -' \
|
||||
&& sh -c 'echo "deb https://packages-eu.bigbluebutton.org/xenial-22 bigbluebutton-xenial main" > /etc/apt/sources.list.d/bigbluebutton.list' \
|
||||
&& apt-get update
|
||||
&& sh -c 'echo "deb https://packages-eu.bigbluebutton.org/xenial-22 bigbluebutton-xenial main" > /etc/apt/sources.list.d/bigbluebutton.list'
|
||||
|
||||
# create dummy packages to satisfy dependencies
|
||||
RUN equivs-control redis-server.control \
|
||||
@ -39,45 +37,39 @@ RUN equivs-control redis-server.control \
|
||||
&& dpkg -i /*.deb \
|
||||
&& rm /*.deb
|
||||
|
||||
# -- create dummy service to avoid start up errors
|
||||
COPY dummy.service /etc/systemd/system/redis-server.service
|
||||
|
||||
RUN apt-get install -y bbb-web bbb-freeswitch-core \
|
||||
RUN apt-get update && apt-get install -y bbb-web \
|
||||
bbb-fsesl-akka bbb-apps-akka bbb-transcode-akka bbb-apps \
|
||||
bbb-apps-video bbb-apps-screenshare bbb-apps-video-broadcast
|
||||
|
||||
# disable IPv6 support
|
||||
RUN rm -rf /opt/freeswitch/conf/sip_profiles/*-ipv6*
|
||||
|
||||
# -- avoid blocking java
|
||||
# https://github.com/bigbluebutton/bigbluebutton/issues/8959
|
||||
RUN sed -i 's|securerandom.source=file:/dev/random|securerandom.source=file:/dev/urandom|g' /usr/lib/jvm/java-8-openjdk-amd64/jre/lib/security/java.security
|
||||
|
||||
# -- Disable unneeded services
|
||||
RUN find /etc/systemd/ | grep wants | xargs -r -n 1 basename | grep service | grep -v networking | grep -v tty | xargs -r -n 1 -I __ systemctl disable __
|
||||
RUN systemctl disable systemd-journal-flush systemd-update-utmp.service
|
||||
RUN systemctl enable red5 freeswitch bbb-apps-akka bbb-transcode-akka bbb-fsesl-akka bbb-web # bbb-rap-caption-inbox
|
||||
|
||||
|
||||
COPY entrypoint.sh /entrypoint.sh
|
||||
|
||||
# -- copy configuration files
|
||||
COPY red5.properties /usr/share/red5/conf/red5.properties
|
||||
COPY bigbluebutton.properties /usr/share/red5/webapps/bigbluebutton/WEB-INF/bigbluebutton.properties
|
||||
COPY bigbluebutton-sip.properties /usr/share/red5/webapps/sip/WEB-INF/bigbluebutton-sip.properties
|
||||
COPY bigbluebutton.yml /usr/local/bigbluebutton/core/scripts/bigbluebutton.yml
|
||||
COPY red5-webapps/bigbluebutton/application.conf /usr/share/red5/webapps/bigbluebutton/WEB-INF/classes/application.conf
|
||||
COPY red5-webapps/bigbluebutton/bigbluebutton.properties /usr/share/red5/webapps/bigbluebutton/WEB-INF/bigbluebutton.properties
|
||||
COPY red5-webapps/bigbluebutton/redis.properties /usr/share/red5/webapps/bigbluebutton/WEB-INF/redis.properties
|
||||
COPY red5-webapps/sip/bigbluebutton-sip.properties /usr/share/red5/webapps/sip/WEB-INF/bigbluebutton-sip.properties
|
||||
COPY red5-webapps/screenshare/screenshare.properties /usr/share/red5/webapps/screenshare/WEB-INF/screenshare.properties
|
||||
COPY red5-webapps/screenshare/screenshare-app.conf /usr/share/red5/webapps/screenshare/WEB-INF/classes/screenshare-app.conf
|
||||
COPY red5-webapps/screenshare/application.conf /usr/share/red5/webapps/screenshare/WEB-INF/classes/application.conf
|
||||
COPY red5-webapps/video/bigbluebutton-video.properties /usr/share/red5/webapps/video/WEB-INF/bigbluebutton-video.properties
|
||||
COPY red5-webapps/video-broadcast/video-broadcast.properties /usr/share/red5/webapps/video-broadcast/WEB-INF/video-broadcast.properties
|
||||
|
||||
COPY freeswitch/vars.xml /opt/freeswitch/conf/vars.xml.tmpl
|
||||
COPY freeswitch/external.xml /opt/freeswitch/conf/sip_profiles/external.xml
|
||||
COPY freeswitch/acl.conf.xml /opt/freeswitch/conf/autoload_configs/acl.conf.xml
|
||||
COPY freeswitch/event_socket.conf.xml /opt/freeswitch/conf/autoload_configs/event_socket.conf.xml
|
||||
COPY freeswitch/dialplan_public.xml /opt/freeswitch/conf/dialplan/public.xml
|
||||
COPY bigbluebutton.yml /usr/local/bigbluebutton/core/scripts/bigbluebutton.yml
|
||||
|
||||
COPY web/bigbluebutton.properties /usr/share/bbb-web/WEB-INF/classes/bigbluebutton.properties.tmpl
|
||||
COPY bbb-apps-akka/application.conf /usr/share/bbb-apps-akka/conf/application.conf.tmpl
|
||||
COPY bbb-fsesl-akka/application.conf /etc/bbb-fsesl-akka/application.conf
|
||||
COPY bbb-transcode-akka/application.conf /etc/bbb-transcode-akka/application.conf
|
||||
COPY web-run.sh /usr/share/bbb-web/run-prod.sh
|
||||
|
||||
COPY supervisord.conf /etc/supervisor/conf.d/supervisord.conf
|
||||
COPY entrypoint.sh /entrypoint.sh
|
||||
|
||||
COPY prefix-log /usr/local/bin/prefix-log
|
||||
RUN mkdir -p /var/log/supervisor
|
||||
|
||||
ENTRYPOINT ["/entrypoint.sh"]
|
||||
CMD []
|
||||
|
||||
|
@ -1,7 +1,6 @@
|
||||
# bbb-core
|
||||
based on the bigbluebutton/docker with bbb-install.sh setup, but got so far reduced to following components:
|
||||
- bbb-web
|
||||
- bbb-freeswitch-core
|
||||
- bbb-fsesl-akka
|
||||
- bbb-apps-akka
|
||||
- bbb-transcode-akka
|
||||
|
@ -65,7 +65,7 @@ sharedNotes {
|
||||
}
|
||||
|
||||
http {
|
||||
interface = "10.7.7.1"
|
||||
interface = "10.7.7.2"
|
||||
port = 9999
|
||||
}
|
||||
|
||||
|
48
mod/core/bbb-transcode-akka/application.conf
Normal file
48
mod/core/bbb-transcode-akka/application.conf
Normal file
@ -0,0 +1,48 @@
|
||||
akka {
|
||||
actor {
|
||||
debug {
|
||||
receive = on
|
||||
}
|
||||
}
|
||||
loggers = ["akka.event.slf4j.Slf4jLogger"]
|
||||
loglevel = INFO
|
||||
stdout-loglevel = "INFO"
|
||||
|
||||
redis-subscriber-worker-dispatcher {
|
||||
mailbox-type = "akka.dispatch.SingleConsumerOnlyUnboundedMailbox"
|
||||
# Throughput defines the maximum number of messages to be
|
||||
# processed per actor before the thread jumps to the next actor.
|
||||
# Set to 1 for as fair as possible.
|
||||
throughput = 512
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
redis {
|
||||
host="redis"
|
||||
port=6379
|
||||
password=""
|
||||
# recording keys should expire in 14 days
|
||||
keyExpiry=1209600
|
||||
}
|
||||
|
||||
videoconference {
|
||||
#The image to use in the videoconference window and/or when the webuser has no video
|
||||
videoconf-logo-image-path = /usr/share/red5/webapps/sip/WEB-INF/mconf-videoconf-logo.gif
|
||||
|
||||
#Enable username subtitle on video-conf-logo (the one shown in sip-phone when
|
||||
#webconference's talker has no video )
|
||||
enable-user-video-subtitle = true
|
||||
|
||||
#To change the sip video resolution, edit below:
|
||||
#IMPORTANT: For now, we only accept these 3 resolutions: 160x120, 320x240, 640x480
|
||||
sip-video-resolution=640x480
|
||||
}
|
||||
|
||||
transcoder {
|
||||
#The path where ffmpeg is installed
|
||||
ffmpeg-path = /usr/bin/ffmpeg
|
||||
|
||||
#The path where ffprobe is installed
|
||||
ffprobe-path = /usr/bin/ffprobe
|
||||
}
|
@ -14,7 +14,7 @@ notes_formats:
|
||||
- etherpad
|
||||
- html
|
||||
- pdf
|
||||
redis_host: 127.0.0.1
|
||||
redis_host: redis
|
||||
redis_port: 6379
|
||||
# Uncomment and set password if redis require it.
|
||||
# redis_password: changeme
|
||||
|
@ -1,9 +0,0 @@
|
||||
[Unit]
|
||||
Description=dummy
|
||||
|
||||
[Service]
|
||||
ExecStart=/bin/sleep 30d
|
||||
ExecReload=/bin/echo reload
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
@ -1,7 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
# print logs to stdout/stderr as soon as systemd is started
|
||||
sh -c 'sleep 5 && journalctl -f' &
|
||||
|
||||
# generate bbb folders
|
||||
mkdir -p /var/bigbluebutton/recording/raw
|
||||
@ -19,7 +17,6 @@ mkdir -p /var/bigbluebutton/unpublished
|
||||
RUN chown bigbluebutton:bigbluebutton /var/bigbluebutton
|
||||
|
||||
dockerize \
|
||||
-template /opt/freeswitch/conf/vars.xml.tmpl:/opt/freeswitch/conf/vars.xml \
|
||||
-template /usr/share/bbb-web/WEB-INF/classes/bigbluebutton.properties.tmpl:/usr/share/bbb-web/WEB-INF/classes/bigbluebutton.properties \
|
||||
-template /usr/share/bbb-apps-akka/conf/application.conf.tmpl:/usr/share/bbb-apps-akka/conf/application.conf \
|
||||
/bin/systemd --system --unit=multi-user.target
|
||||
/usr/bin/supervisord --nodaemon
|
||||
|
16
mod/core/prefix-log
Executable file
16
mod/core/prefix-log
Executable file
@ -0,0 +1,16 @@
|
||||
#!/usr/bin/env bash
|
||||
# setup fd-3 to point to the original stdout
|
||||
exec 3>&1
|
||||
# setup fd-4 to point to the original stderr
|
||||
exec 4>&2
|
||||
|
||||
# get the prefix from SUPERVISOR_PROCESS_NAME environement variable
|
||||
printf -v PREFIX "%-14.14s" ${SUPERVISOR_PROCESS_NAME}
|
||||
|
||||
# reassign stdout and stderr to a preprocessed and redirected to the original stdout/stderr (3 and 4) we have create eralier
|
||||
exec 1> >( perl -ne '$| = 1; print "'"${PREFIX}"' | $_"' >&3)
|
||||
exec 2> >( perl -ne '$| = 1; print "'"${PREFIX}"' | $_"' >&4)
|
||||
|
||||
# from here on everthing that outputs to stdout/stderr will be go through the perl script
|
||||
|
||||
exec "$@"
|
43
mod/core/red5-webapps/bigbluebutton/application.conf
Normal file
43
mod/core/red5-webapps/bigbluebutton/application.conf
Normal file
@ -0,0 +1,43 @@
|
||||
akka {
|
||||
actor {
|
||||
debug {
|
||||
# enable DEBUG logging of all AutoReceiveMessages (Kill, PoisonPill et.c.)
|
||||
autoreceive = on
|
||||
# enable DEBUG logging of actor lifecycle changes
|
||||
lifecycle = on
|
||||
}
|
||||
}
|
||||
loggers = ["akka.event.slf4j.Slf4jLogger"]
|
||||
loglevel = "DEBUG"
|
||||
|
||||
redis-publish-worker-dispatcher {
|
||||
mailbox-type = "akka.dispatch.SingleConsumerOnlyUnboundedMailbox"
|
||||
# Throughput defines the maximum number of messages to be
|
||||
# processed per actor before the thread jumps to the next actor.
|
||||
# Set to 1 for as fair as possible.
|
||||
throughput = 512
|
||||
}
|
||||
|
||||
redis-subscriber-worker-dispatcher {
|
||||
mailbox-type = "akka.dispatch.SingleConsumerOnlyUnboundedMailbox"
|
||||
# Throughput defines the maximum number of messages to be
|
||||
# processed per actor before the thread jumps to the next actor.
|
||||
# Set to 1 for as fair as possible.
|
||||
throughput = 512
|
||||
}
|
||||
}
|
||||
|
||||
redis {
|
||||
host="redis"
|
||||
port=6379
|
||||
password=""
|
||||
# recording keys should expire in 14 days
|
||||
keyExpiry=1209600
|
||||
}
|
||||
|
||||
eventBus {
|
||||
meetingManagerChannel = "FROM APPLICATION.CONF MeetingManagerChannel"
|
||||
outMessageChannel = "OutgoingMessageChannel"
|
||||
incomingJsonMsgChannel = "IncomingJsonMsgChannel"
|
||||
outBbbMsgMsgChannel = "OutBbbMsgChannel"
|
||||
}
|
@ -23,7 +23,7 @@ freeswitch.esl.host=10.7.7.1
|
||||
freeswitch.esl.port=8021
|
||||
freeswitch.esl.password=ClueCon
|
||||
|
||||
redisHost=10.7.7.5
|
||||
redisHost=redis
|
||||
redisPort=6379
|
||||
redisPassword=
|
||||
redisExpireKey=1209600
|
5
mod/core/red5-webapps/bigbluebutton/redis.properties
Normal file
5
mod/core/red5-webapps/bigbluebutton/redis.properties
Normal file
@ -0,0 +1,5 @@
|
||||
# Redis settings
|
||||
|
||||
redis.host=redis
|
||||
redis.port=6379
|
||||
redis.pass=
|
43
mod/core/red5-webapps/screenshare/application.conf
Normal file
43
mod/core/red5-webapps/screenshare/application.conf
Normal file
@ -0,0 +1,43 @@
|
||||
akka {
|
||||
actor {
|
||||
debug {
|
||||
# enable DEBUG logging of all AutoReceiveMessages (Kill, PoisonPill et.c.)
|
||||
autoreceive = on
|
||||
# enable DEBUG logging of actor lifecycle changes
|
||||
lifecycle = on
|
||||
}
|
||||
}
|
||||
loggers = ["akka.event.slf4j.Slf4jLogger"]
|
||||
loglevel = "DEBUG"
|
||||
|
||||
redis-publish-worker-dispatcher {
|
||||
mailbox-type = "akka.dispatch.SingleConsumerOnlyUnboundedMailbox"
|
||||
# Throughput defines the maximum number of messages to be
|
||||
# processed per actor before the thread jumps to the next actor.
|
||||
# Set to 1 for as fair as possible.
|
||||
throughput = 512
|
||||
}
|
||||
|
||||
redis-subscriber-worker-dispatcher {
|
||||
mailbox-type = "akka.dispatch.SingleConsumerOnlyUnboundedMailbox"
|
||||
# Throughput defines the maximum number of messages to be
|
||||
# processed per actor before the thread jumps to the next actor.
|
||||
# Set to 1 for as fair as possible.
|
||||
throughput = 512
|
||||
}
|
||||
}
|
||||
|
||||
redis {
|
||||
host="redis"
|
||||
port=6379
|
||||
password=""
|
||||
# recording keys should expire in 14 days
|
||||
keyExpiry=1209600
|
||||
}
|
||||
|
||||
eventBus {
|
||||
meetingManagerChannel = "FROM APPLICATION.CONF MeetingManagerChannel"
|
||||
outMessageChannel = "OutgoingMessageChannel"
|
||||
incomingJsonMsgChannel = "IncomingJsonMsgChannel"
|
||||
outBbbMsgMsgChannel = "OutBbbMsgChannel"
|
||||
}
|
43
mod/core/red5-webapps/screenshare/screenshare-app.conf
Normal file
43
mod/core/red5-webapps/screenshare/screenshare-app.conf
Normal file
@ -0,0 +1,43 @@
|
||||
akka {
|
||||
actor {
|
||||
debug {
|
||||
# enable DEBUG logging of all AutoReceiveMessages (Kill, PoisonPill et.c.)
|
||||
autoreceive = on
|
||||
# enable DEBUG logging of actor lifecycle changes
|
||||
lifecycle = on
|
||||
}
|
||||
}
|
||||
loggers = ["akka.event.slf4j.Slf4jLoggerDDD"]
|
||||
loglevel = "DEBUG"
|
||||
|
||||
redis-publish-worker-dispatcher {
|
||||
mailbox-type = "akka.dispatch.SingleConsumerOnlyUnboundedMailbox"
|
||||
# Throughput defines the maximum number of messages to be
|
||||
# processed per actor before the thread jumps to the next actor.
|
||||
# Set to 1 for as fair as possible.
|
||||
throughput = 512
|
||||
}
|
||||
|
||||
redis-subscriber-worker-dispatcher {
|
||||
mailbox-type = "akka.dispatch.SingleConsumerOnlyUnboundedMailbox"
|
||||
# Throughput defines the maximum number of messages to be
|
||||
# processed per actor before the thread jumps to the next actor.
|
||||
# Set to 1 for as fair as possible.
|
||||
throughput = 512
|
||||
}
|
||||
}
|
||||
|
||||
redis {
|
||||
host="redis"
|
||||
port=6379
|
||||
password=""
|
||||
# recording keys should expire in 14 days
|
||||
keyExpiry=1209600
|
||||
}
|
||||
|
||||
eventBus {
|
||||
meetingManagerChannel = "FROM SCREEN-APPLICATION.CONF MeetingManagerChannel"
|
||||
outMessageChannel = "OutgoingMessageChannel"
|
||||
incomingJsonMsgChannel = "IncomingJsonMsgChannel"
|
||||
outBbbMsgMsgChannel = "OutBbbMsgChannel"
|
||||
}
|
20
mod/core/red5-webapps/screenshare/screenshare.properties
Normal file
20
mod/core/red5-webapps/screenshare/screenshare.properties
Normal file
@ -0,0 +1,20 @@
|
||||
recordingDirectory=/usr/share/red5/webapps/screenshare/streams
|
||||
|
||||
redis.host=redis
|
||||
redis.port=6379
|
||||
redis.password=
|
||||
redis.keyExpiry=1209600
|
||||
|
||||
streamBaseUrl=rtmp://10.130.218.38/screenshare
|
||||
jnlpUrl=http://10.130.218.38/screenshare
|
||||
jnlpFile=http://10.130.218.38/screenshare/screenshare.jnlp
|
||||
useH264=false
|
||||
|
||||
# NOTES:
|
||||
# 1. GOP (group of pictures) is calculated as frameRate * keyFrameInterval
|
||||
# 2. intra-refresh=1 doesn't work in Chrome. Late comers can't view the stream as
|
||||
# the user missed the key frame
|
||||
# 3. keyFrameInterval is in seconds
|
||||
# 4. Make sure you encode & into & as it will break the JNLP XML
|
||||
#codecOptions=crf=36&preset=veryfast&tune=animation,zerolatency&frameRate=12.0&keyFrameInterval=6
|
||||
codecOptions=crf=38&preset=veryfast&tune=zerolatency&frameRate=5.0&keyFrameInterval=5
|
@ -8,7 +8,7 @@ sip.server.username=bbbuser
|
||||
sip.server.password=secret
|
||||
|
||||
# The ip and port of the FreeSWITCH server
|
||||
freeswitch.ip=127.0.0.1
|
||||
freeswitch.ip=10.7.7.1
|
||||
freeswitch.port=5060
|
||||
|
||||
# The start/stop RTP port the application is going to use
|
@ -0,0 +1,2 @@
|
||||
redis.host=redis
|
||||
redis.port=6379
|
@ -0,0 +1,5 @@
|
||||
redis.host=redis
|
||||
redis.port=6379
|
||||
redis.password=
|
||||
# recording keys should expire in 14 days
|
||||
redis.keyExpiry=1209600
|
@ -1,157 +0,0 @@
|
||||
# Socket policy
|
||||
policy.host=10.7.7.1
|
||||
policy.port=843
|
||||
|
||||
# HTTP
|
||||
http.host=10.7.7.1
|
||||
http.port=5080
|
||||
https.port=5443
|
||||
http.URIEncoding=UTF-8
|
||||
http.max_headers_size=8192
|
||||
http.max_keep_alive_requests=-1
|
||||
http.max_threads=20
|
||||
http.acceptor_thread_count=10
|
||||
http.processor_cache=20
|
||||
|
||||
# RTMP
|
||||
rtmp.host=10.7.7.1
|
||||
rtmp.port=1935
|
||||
rtmp.io_threads=8
|
||||
rtmp.send_buffer_size=65536
|
||||
rtmp.receive_buffer_size=65536
|
||||
rtmp.ping_interval=1000
|
||||
rtmp.max_inactivity=20000
|
||||
rtmp.max_handshake_time=5000
|
||||
rtmp.tcp_nodelay=true
|
||||
rtmp.tcp_keepalive=false
|
||||
rtmp.default_server_bandwidth=10000000
|
||||
rtmp.default_client_bandwidth=10000000
|
||||
rtmp.client_bandwidth_limit_type=2
|
||||
rtmp.bandwidth_detection=false
|
||||
rtmp.encoder_base_tolerance=5000
|
||||
rtmp.encoder_drop_live_future=false
|
||||
# traffic optimization hinting. to disable set traffic class set to -1
|
||||
# low delay + high throughput == 24 (0x18)
|
||||
rtmp.traffic_class=-1
|
||||
# requested maximum length of the queue of incoming connections
|
||||
rtmp.backlog=32
|
||||
# the interval (seconds) between each throughput calculation
|
||||
rtmp.thoughput_calc_interval=15
|
||||
# enable use of the default mina acceptor
|
||||
rtmp.default_acceptor=true
|
||||
# socket i/o pool sizes used when default acceptor is disabled
|
||||
rtmp.initial_pool_size=0
|
||||
rtmp.max_pool_size=2
|
||||
rtmp.max_processor_pool_size=8
|
||||
rtmp.executor_keepalive_time=60000
|
||||
mina.logfilter.enable=false
|
||||
# scheduler configs (per application)
|
||||
rtmp.scheduler.pool_size=8
|
||||
rtmp.deadlockguard.sheduler.pool_size=8
|
||||
# message executor configs (per application) - adjust these as needed if you get tasks rejected
|
||||
rtmp.executor.core_pool_size=4
|
||||
rtmp.executor.max_pool_size=32
|
||||
rtmp.executor.queue_capacity=64
|
||||
# drop audio packets when queue is almost full, to disable this, set to 0
|
||||
rtmp.executor.queue_size_to_drop_audio_packets=60
|
||||
# maximum amount of time allotted to process a single rtmp message / packet in milliseconds, set it as 0 to disable timeout
|
||||
rtmp.max_handling_time=2000
|
||||
# connection tweaks - dont modify unless you know what you're doing
|
||||
rtmp.channel.initial.capacity=3
|
||||
rtmp.channel.concurrency.level=1
|
||||
rtmp.stream.initial.capacity=1
|
||||
rtmp.stream.concurrency.level=1
|
||||
rtmp.pending.calls.initial.capacity=3
|
||||
rtmp.pending.calls.concurrency.level=1
|
||||
rtmp.reserved.streams.initial.capacity=1
|
||||
rtmp.reserved.streams.concurrency.level=1
|
||||
rtmp.generateMetadata=false
|
||||
# maximum packet size allowed in bytes
|
||||
rtmp.max_packet_size=3145728
|
||||
|
||||
# RTMPS
|
||||
rtmps.host=10.7.7.1
|
||||
rtmps.port=8443
|
||||
rtmps.ping_interval=5000
|
||||
rtmps.max_inactivity=20000
|
||||
rtmps.max_keep_alive_requests=-1
|
||||
rtmps.max_threads=8
|
||||
rtmps.acceptor_thread_count=2
|
||||
rtmps.processor_cache=20
|
||||
# RTMPS Key and Trust store parameters
|
||||
rtmps.keystorepass=password
|
||||
rtmps.keystorefile=conf/keystore.jks
|
||||
rtmps.truststorepass=password
|
||||
rtmps.truststorefile=conf/truststore.jks
|
||||
|
||||
# RTMPT
|
||||
rtmpt.host=10.7.7.1
|
||||
rtmpt.port=8088
|
||||
rtmpt.ping_interval=5000
|
||||
rtmpt.max_inactivity=20000
|
||||
rtmpt.max_handshake_time=5000
|
||||
rtmpt.max_keep_alive_requests=-1
|
||||
rtmpt.max_threads=8
|
||||
rtmpt.acceptor_thread_count=2
|
||||
rtmpt.processor_cache=20
|
||||
rtmpt.encoder_base_tolerance=5000
|
||||
rtmpt.encoder_drop_live_future=true
|
||||
# better setting for streaming media
|
||||
rtmpt.target_reponse_size=32768
|
||||
# best setting for small messages or shared objects
|
||||
#rtmpt.target_reponse_size=8192
|
||||
# max incoming messages to process at a time. the most that FP appears to send is 166
|
||||
rtmpt.max_in_msg_process=166
|
||||
# max time in millis that we will wait when offering data to the in or out queue
|
||||
rtmpt.max_queue_offer_time=125
|
||||
# max offer attempts
|
||||
rtmpt.max_queue_offer_attempts=4
|
||||
|
||||
# WebSocket
|
||||
ws.host=10.7.7.1
|
||||
ws.port=8081
|
||||
|
||||
# Debug proxy (needs to be activated in red5-core.xml)
|
||||
proxy.source_host=127.0.0.1
|
||||
proxy.source_port=1936
|
||||
proxy.destination_host=127.0.0.1
|
||||
proxy.destination_port=1935
|
||||
|
||||
# JMX
|
||||
jmx.rmi.host=localhost
|
||||
jmx.rmi.port=9999
|
||||
jmx.rmi.sport=9998
|
||||
jmx.rmi.port.remoteobjects=
|
||||
jmx.keystorepass=password
|
||||
jmx.mina.monitor.enable=false
|
||||
jmx.mina.poll.interval=1000
|
||||
# Whether to always create the registry in-process, not attempting to
|
||||
# locate an existing registry at the specified port. Set to "true" in order
|
||||
# to avoid the overhead of locating an existing registry when you always intend
|
||||
# to create a new registry in any case.
|
||||
jmx.registry.create=true
|
||||
# Whether or not the MBeanServerFactoryBean should attempt to locate a running
|
||||
# MBeanServer before creating one
|
||||
jmx.reuse.existing.server=true
|
||||
# Whether to register the MBeanServer with the MBeanServerFactory, making it
|
||||
# available through MBeanServerFactory.findMBeanServer()
|
||||
jmx.register.factory=true
|
||||
# Whether any threads started for the JMXConnectorServer should be started as daemon threads
|
||||
jmx.daemon=true
|
||||
# Whether the JMXConnectorServer should be started in a separate thread
|
||||
jmx.threaded=true
|
||||
|
||||
# Server properties
|
||||
# max events to send in a single update
|
||||
so.max.events.per.update=64
|
||||
so.scheduler.pool_size=4
|
||||
keyframe.cache.entry.max=500
|
||||
war.deploy.server.check.interval=600000
|
||||
fileconsumer.delayed.write=true
|
||||
fileconsumer.queue.size=120
|
||||
fileconsumer.wait.for.keyframe=true
|
||||
subscriberstream.buffer.check.interval=5000
|
||||
subscriberstream.underrun.trigger=100
|
||||
subscriberstream.max.pending.frames=10
|
||||
subscriberstream.max.sequential.frames=10
|
||||
broadcaststream.auto.record=false
|
46
mod/core/supervisord.conf
Normal file
46
mod/core/supervisord.conf
Normal file
@ -0,0 +1,46 @@
|
||||
[program:red5]
|
||||
command=/usr/local/bin/prefix-log /usr/share/red5/red5.sh
|
||||
user=red5
|
||||
directory=/usr/share/red5
|
||||
stdout_logfile=/dev/fd/1
|
||||
stdout_logfile_maxbytes=0
|
||||
stderr_logfile=/dev/fd/2
|
||||
stderr_logfile_maxbytes=0
|
||||
|
||||
[program:bbb-web]
|
||||
command=/usr/local/bin/prefix-log /usr/share/bbb-web/run-prod.sh
|
||||
user=bigbluebutton
|
||||
directory=/usr/share/bbb-web
|
||||
stdout_logfile=/dev/fd/1
|
||||
stdout_logfile_maxbytes=0
|
||||
stderr_logfile=/dev/fd/2
|
||||
stderr_logfile_maxbytes=0
|
||||
|
||||
[program:bbb-apps-akka]
|
||||
command=/usr/local/bin/prefix-log /usr/share/bbb-apps-akka/bin/bbb-apps-akka
|
||||
user=bigbluebutton
|
||||
directory=/usr/share/bbb-apps-akka
|
||||
stdout_logfile=/dev/fd/1
|
||||
stdout_logfile_maxbytes=0
|
||||
stderr_logfile=/dev/fd/2
|
||||
stderr_logfile_maxbytes=0
|
||||
|
||||
[program:bbb-fsesl-akka]
|
||||
command=/usr/local/bin/prefix-log /usr/share/bbb-fsesl-akka/bin/bbb-fsesl-akka
|
||||
user=bigbluebutton
|
||||
directory=/usr/share/bbb-fsesl-akka
|
||||
stdout_logfile=/dev/fd/1
|
||||
stdout_logfile_maxbytes=0
|
||||
stderr_logfile=/dev/fd/2
|
||||
stderr_logfile_maxbytes=0
|
||||
|
||||
[program:bbb-transcode-akka]
|
||||
command=/usr/local/bin/prefix-log /usr/share/bbb-transcode-akka/bin/bbb-transcode-akka
|
||||
user=bigbluebutton
|
||||
directory=/usr/share/bbb-transcode-akka
|
||||
stdout_logfile=/dev/fd/1
|
||||
stdout_logfile_maxbytes=0
|
||||
stderr_logfile=/dev/fd/2
|
||||
stderr_logfile_maxbytes=0
|
||||
|
||||
|
@ -264,7 +264,7 @@ securitySalt={{ .Env.SHARED_SECRET }}
|
||||
# Directory where we drop the <meeting-id-recorded>.done file
|
||||
recordStatusDir=/var/bigbluebutton/recording/status/recorded
|
||||
|
||||
redisHost=127.0.0.1
|
||||
redisHost=redis
|
||||
redisPort=6379
|
||||
redisPassword=
|
||||
redisKeyExpiry=1209600
|
||||
|
83
mod/freeswitch/Dockerfile
Normal file
83
mod/freeswitch/Dockerfile
Normal file
@ -0,0 +1,83 @@
|
||||
FROM debian:buster-slim
|
||||
|
||||
# add freeswitch repo
|
||||
RUN apt-get update && \
|
||||
apt-get install -y --no-install-recommends subversion curl wget ca-certificates gnupg gnupg2 lsb-release && \
|
||||
curl -k https://files.freeswitch.org/repo/deb/debian-release/fsstretch-archive-keyring.asc | apt-key add - && \
|
||||
echo 'deb http://files.freeswitch.org/repo/deb/debian-release/ buster main' > /etc/apt/sources.list.d/freeswitch.list
|
||||
|
||||
# install dockerize
|
||||
ENV DOCKERIZE_VERSION v0.6.1
|
||||
RUN wget https://github.com/jwilder/dockerize/releases/download/$DOCKERIZE_VERSION/dockerize-linux-amd64-$DOCKERIZE_VERSION.tar.gz \
|
||||
&& tar -C /usr/local/bin -xzvf dockerize-linux-amd64-$DOCKERIZE_VERSION.tar.gz \
|
||||
&& rm dockerize-linux-amd64-$DOCKERIZE_VERSION.tar.gz
|
||||
|
||||
# install freeswitch
|
||||
RUN apt-get update && apt-get install -y \
|
||||
freeswitch \
|
||||
freeswitch-mod-amr \
|
||||
freeswitch-mod-b64 \
|
||||
freeswitch-mod-commands \
|
||||
freeswitch-mod-conference \
|
||||
freeswitch-mod-console \
|
||||
freeswitch-mod-db \
|
||||
freeswitch-mod-dialplan-asterisk \
|
||||
freeswitch-mod-dialplan-xml \
|
||||
freeswitch-mod-dptools \
|
||||
freeswitch-mod-enum \
|
||||
freeswitch-mod-esf \
|
||||
freeswitch-mod-event-socket \
|
||||
freeswitch-mod-expr \
|
||||
freeswitch-mod-fifo \
|
||||
freeswitch-mod-fsv \
|
||||
freeswitch-mod-g723-1 \
|
||||
freeswitch-mod-g729 \
|
||||
freeswitch-mod-hash \
|
||||
freeswitch-mod-httapi \
|
||||
freeswitch-mod-local-stream \
|
||||
freeswitch-mod-logfile \
|
||||
freeswitch-mod-loopback \
|
||||
freeswitch-mod-lua \
|
||||
freeswitch-mod-native-file \
|
||||
freeswitch-mod-opusfile \
|
||||
freeswitch-mod-opus \
|
||||
freeswitch-mod-png \
|
||||
freeswitch-mod-rtc \
|
||||
freeswitch-mod-say-en \
|
||||
freeswitch-mod-sndfile \
|
||||
freeswitch-mod-sofia \
|
||||
freeswitch-mod-spandsp \
|
||||
freeswitch-mod-tone-stream \
|
||||
freeswitch-mod-verto \
|
||||
freeswitch-sounds-en-us-callie
|
||||
|
||||
# Potentially missing
|
||||
# (included in bbb-freeswitch-core but not referenced in https://github.com/bigbluebutton/bigbluebutton/issues/9064)
|
||||
# freeswitch-mod-cdr-csv
|
||||
# freeswitch-mod-cdr-sqlite
|
||||
# freeswitch-mod-h26x
|
||||
# freeswitch-mod-skinny
|
||||
# freeswitch-mod-sms
|
||||
# freeswitch-mod-syslog
|
||||
# freeswitch-mod-valet-parking
|
||||
# freeswitch-mod-voicemail
|
||||
# freeswitch-mod-xml-cdr
|
||||
# freeswitch-mod-xml-rpc
|
||||
# freeswitch-mod-xml-scgi
|
||||
|
||||
|
||||
# -- get official bbb freeswitch config
|
||||
# we use svn for retrieving the files since the repo is quite large,
|
||||
# git sparse-checkout is not yet available with buster and there
|
||||
# is no other sane way of downloading a single directory via git
|
||||
ENV GIT_TAG v2.2.9-freeswitch
|
||||
RUN cd /etc \
|
||||
&& svn checkout https://github.com/alangecker/bbb-packages/tags/$GIT_TAG/bbb-freeswitch-core/data/opt/freeswitch/etc/freeswitch \
|
||||
&& rm -rf /etc/freeswitch/.svn
|
||||
|
||||
# add modifications
|
||||
COPY ./conf /etc/freeswitch/
|
||||
|
||||
|
||||
COPY ./entrypoint.sh /entrypoint.sh
|
||||
ENTRYPOINT /entrypoint.sh
|
4
mod/freeswitch/conf/sip_profiles/external-ipv6.xml
Normal file
4
mod/freeswitch/conf/sip_profiles/external-ipv6.xml
Normal file
@ -0,0 +1,4 @@
|
||||
<!--
|
||||
IPv6 is disabled for now since there a some more configurations needed
|
||||
to make it work beautifully
|
||||
-->
|
5
mod/freeswitch/entrypoint.sh
Executable file
5
mod/freeswitch/entrypoint.sh
Executable file
@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
dockerize \
|
||||
-template /etc/freeswitch/vars.xml.tmpl:/etc/freeswitch/vars.xml \
|
||||
/usr/bin/freeswitch -u freeswitch -g daemon -nonat -nf
|
@ -1,7 +1,7 @@
|
||||
# Handle desktop sharing tunneling. Forwards
|
||||
# requests to Red5 on port 5080.
|
||||
location /screenshare {
|
||||
proxy_pass http://host.docker.internal:5080;
|
||||
proxy_pass http://core:5080;
|
||||
proxy_redirect default;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
client_max_body_size 10m;
|
||||
|
@ -3,7 +3,7 @@
|
||||
proxy_http_version 1.1;
|
||||
|
||||
location /bigbluebutton {
|
||||
proxy_pass http://host.docker.internal:8090;
|
||||
proxy_pass http://core:8090;
|
||||
proxy_redirect default;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
|
||||
@ -13,7 +13,7 @@
|
||||
|
||||
|
||||
location ~ "^\/bigbluebutton\/presentation\/(?<prestoken>[a-zA-Z0-9_-]+)/upload$" {
|
||||
proxy_pass http://host.docker.internal:8090;
|
||||
proxy_pass http://core:8090;
|
||||
proxy_redirect default;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
|
||||
@ -50,14 +50,14 @@
|
||||
if ($arg_presFilename !~ "^[0-9a-zA-Z]+\.[0-9a-zA-Z]+$") {
|
||||
return 404;
|
||||
}
|
||||
proxy_pass http://host.docker.internal:8090$uri$is_args$args;
|
||||
proxy_pass http://core:8090$uri$is_args$args;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
# Workaround IE refusal to set cookies in iframe
|
||||
add_header P3P 'CP="No P3P policy available"';
|
||||
}
|
||||
|
||||
location = /bigbluebutton/presentation/checkPresentation {
|
||||
proxy_pass http://host.docker.internal:8090;
|
||||
proxy_pass http://core:8090;
|
||||
proxy_redirect default;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
|
||||
@ -82,7 +82,7 @@
|
||||
# and make sure to add sessionToken param in the request URI
|
||||
location = /bigbluebutton/connection/checkAuthorization {
|
||||
internal;
|
||||
proxy_pass http://host.docker.internal:8090;
|
||||
proxy_pass http://core:8090;
|
||||
proxy_pass_request_body off;
|
||||
proxy_set_header Content-Length "";
|
||||
proxy_set_header X-Original-URI $request_uri;
|
||||
@ -119,7 +119,7 @@
|
||||
|
||||
location = /bigbluebutton/textTrack/validateAuthToken {
|
||||
internal;
|
||||
proxy_pass http://host.docker.internal:8090;
|
||||
proxy_pass http://core:8090;
|
||||
proxy_redirect default;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
|
||||
|
@ -11,7 +11,7 @@ server {
|
||||
# Handle RTMPT (RTMP Tunneling). Forwards requests
|
||||
# to Red5 on port 5080
|
||||
location ~ (/open/|/close/|/idle/|/send/|/fcs/) {
|
||||
proxy_pass http://10.7.7.1:5080;
|
||||
proxy_pass http://core:5080;
|
||||
proxy_redirect off;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
|
||||
@ -29,7 +29,7 @@ server {
|
||||
# Handle desktop sharing tunneling. Forwards
|
||||
# requests to Red5 on port 5080.
|
||||
location /deskshare {
|
||||
proxy_pass http://10.7.7.1:5080;
|
||||
proxy_pass http://core:5080;
|
||||
proxy_redirect default;
|
||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||
client_max_body_size 10m;
|
||||
|
Loading…
Reference in New Issue
Block a user