diff --git a/DOCKER.md b/DOCKER.md index 055e979af06bb9645d7fa90c45f1cd09c35dbe82..5de8d5a538e83df5f0340d23387f032d1c267f15 100644 --- a/DOCKER.md +++ b/DOCKER.md @@ -5,51 +5,62 @@ mconf@docker-bbb:~/bigbluebutton/labs/docker/sbt$ docker build -t 'sbt:0.13.8' . mconf@docker-bbb:~/bigbluebutton/bbb-common-message$ docker build -t 'bbb-common-message' --build-arg COMMON_VERSION=0.0.1-SNAPSHOT . mconf@docker-bbb:~/bigbluebutton$ docker build -f akka-bbb-apps/Dockerfile -t bbb-apps-akka --build-arg COMMON_VERSION=0.0.1-SNAPSHOT . mconf@docker-bbb:~/bigbluebutton$ docker build -f akka-bbb-transcode/Dockerfile -t bbb-transcode --build-arg COMMON_VERSION=0.0.1-SNAPSHOT . -mconf@docker-bbb:~/bigbluebutton$ docker build -f bigbluebutton-web/Dockerfile -t bbb-web --build-arg COMMON_VERSION=0.0.1-SNAPSHOT . +mconf@docker-bbb:~/bigbluebutton/bigbluebutton-web$ docker build -f Dockerfile -t bbb-web --build-arg COMMON_VERSION=0.0.1-SNAPSHOT . mconf@docker-bbb:~/bigbluebutton$ docker build -f freeswitch.dockerfile -t bbb-freeswitch . mconf@docker-bbb:~/bigbluebutton$ docker build -f akka-bbb-fsesl/Dockerfile -t bbb-fsesl-akka --build-arg COMMON_VERSION=0.0.1-SNAPSHOT . mconf@docker-bbb:~/bigbluebutton$ docker build -f libreoffice.dockerfile -t libreoffice . mconf@docker-bbb:~/bigbluebutton/labs/bbb-webrtc-sfu$ docker build -t bbb-webrtc-sfu . mconf@docker-bbb:~/bigbluebutton/bbb-webhooks$ docker build -t bbb-webhooks . +mconf@felipe-docker:~/bigbluebutton/labs/docker/kurento$ docker build -t kurento . +docker build -t bbb-lti . ``` ## RUN ``` +docker run --rm --name bbb-lti -it -e SHARED_SECRET=123456 -e SERVER_DOMAIN=felipe-docker.mconf.com -e LTI_CONSUMERS=demo:welcome,consumer1:secret1 -p 8888:8080 bbb-lti +# docker run --rm --name coturn -p 3478:3478 -p 3478:3478/udp -d kurento/coturn +docker run --rm --name coturn --net host -d kurento/coturn docker run --rm --name haveged --privileged -d harbur/haveged docker run --rm --name mongo -d mongo:3.4 docker run --rm --name redis -d redis -docker run --rm --name kurento -d kurento/kurento-media-server -docker run --rm --name bbb-html5 -p 3000:3000 --link mongo --link redis -e MONGO_URL=mongodb://mongo/bbbhtml5 -e METEOR_SETTINGS="$(cat private/config/settings-production.json)" -e REDIS_HOST=redis -d bbb-html5 +# docker run --rm --name kurento -d kurento/kurento-media-server +# docker run --rm --name kurento --net host -d kurento/kurento-media-server +docker run --rm --name kurento --net host -d kurento +docker run --rm --name bbb-html5 --link mongo --link redis -e MONGO_URL=mongodb://mongo/bbbhtml5 -e METEOR_SETTINGS="$(cat private/config/settings-production.json)" -e REDIS_HOST=redis -e ROOT_URL=http://127.0.0.1/html5client -d bbb-html5 docker run --rm --name bbb-webhooks -p 3005:3005 --link redis -e REDIS_HOST=redis -d bbb-webhooks docker run --rm --name bbb-apps-akka --link redis -e REDIS_HOST=redis -d bbb-apps-akka docker run --rm --name bbb-transcode --link redis -e REDIS_HOST=redis -d bbb-transcode -# docker run --rm --name bbb-web -p 8080:8080 --link redis -e REDIS_HOST=redis -e BIGBLUEBUTTON_WEB_SERVERURL=https://felipe-docker.mconf.com -e JAVA_OPTS="-Djava.security.egd=file:/dev/./urandom" -d bbb-web -# docker run --rm --name bbb-web -p 8080:8080 --link redis -e REDIS_HOST=redis -e BIGBLUEBUTTON_WEB_SERVERURL=https://felipe-docker.mconf.com -d bbb-web -docker run --rm --name bbb-web -p 8080:8080 --link redis -e REDIS_HOST=redis -e SERVER_URL=https://felipe-docker.mconf.com -d bbb-web - +docker run --rm --name bbb-web --link redis -e REDIS_HOST=redis -e SERVER_URL=https://felipe-docker.mconf.com -d bbb-web +docker run --rm --name greenlight -v $(pwd)/db/production:/usr/src/app/db/production --env-file greenlight.env -d bigbluebutton/greenlight docker run --rm --name bbb-freeswitch -d bbb-freeswitch docker run --rm --name bbb-fsesl-akka --link redis --link bbb-freeswitch -e REDIS_HOST=redis -e ESL_HOST=freeswitch -d bbb-fsesl-akka docker run --rm --name libreoffice -p 8100:8100 -d libreoffice -docker run --rm --name bbb-webrtc-sfu -p 3008:3008 --link redis --link kurento --link bbb-transcode -e KURENTO_IP=206.189.162.193 -e KURENTO_URL=http://kurento:8888/kurento -e TRANSCODE_IP=bbb-transcode -e REDIS_HOST=redis -d bbb-webrtc-sfu +# docker run --rm --name bbb-webrtc-sfu -p 3008:3008 --link redis --link kurento --link bbb-transcode -e KURENTO_IP=206.189.162.193 -e KURENTO_URL=ws://kurento:8888/kurento -e TRANSCODE_IP=bbb-transcode -e REDIS_HOST=redis -d bbb-webrtc-sfu +docker run --rm --name bbb-webrtc-sfu -p 3008:3008 --link redis --link bbb-transcode -e KURENTO_IP=206.189.162.193 -e KURENTO_URL=ws://localhost:8888/kurento -e TRANSCODE_IP=bbb-transcode -e REDIS_HOST=redis -d bbb-webrtc-sfu docker run --rm --name certbot -p 80:80 -v ~/certs:/etc/letsencrypt -it certbot/certbot certonly --non-interactive --register-unsafely-without-email --agree-tos --expand --domain felipe-docker.mconf.com --webroot -w /var/www/bigbluebutton-default/ docker run --rm --name certbot -p 80:80 -v ~/certs:/etc/letsencrypt -it certbot/certbot certonly --non-interactive --register-unsafely-without-email --agree-tos --expand --domain felipe-docker.mconf.com --standalone openssl dhparam -out /root/dhp-2048.pem 2048 -docker run --rm --name nginx --link bbb-webhooks --link bbb-web --link bbb-html5 --link bbb-webrtc-sfu -p 80:80 -p 443:443 -v ~/certs:/etc/letsencrypt -v $(pwd)/dhp-2048.pem:/etc/nginx/ssl/dhp-2048.pem -v $(pwd)/nginx.conf:/etc/nginx/nginx.conf -it nginx +docker run --rm --name nginx --link bbb-webhooks --link bbb-web --link bbb-html5 --link bbb-webrtc-sfu --link greenlight -p 80:80 -p 443:443 -v ~/certs:/etc/letsencrypt -v $(pwd)/dhp-2048.pem:/etc/nginx/ssl/dhp-2048.pem -v $(pwd)/nginx.conf:/etc/nginx/nginx.conf -v $(pwd)/bigbluebutton-client/resources/config.xml.template:/var/www/bigbluebutton/client/conf/config.xml -d nginx docker exec -ti bbb-web cat webapps/bigbluebutton/WEB-INF/classes/bigbluebutton.properties | grep '^securitySalt=' | cut -d'=' -f2 docker exec -ti redis redis-cli monitor + +docker run --rm --name bbb-web --link redis -e -it bbb-web sh -c 'export JAVA_OPTS="$JAVA_OPTS -Djava.security.egd=file:/dev/./urandom -DsecuritySalt=123456 -Dredis.host=redis -Dbigbluebutton.web.serverURL=https://felipe-docker.mconf.com"; sed -i "s|^securerandom\.source=.*|securerandom.source=file:/dev/./urandom|g" $JAVA_HOME/lib/security/java.security; exec catalina.sh run' + + +docker run --rm -v vconfig:/data -ti tannerfe/alpine-openssl openssl dhparam -out /data/nginx/dhp-2048.pem 2048 ``` ## TODO - reboot libreoffice in case of failure - connect bbb-common-web to libreoffice running in a different container (decouple bbb-web from libreoffice); remove libreoffice from bbb-web image - configure ip on freeswitch -- configure to connect to redis: +v configure to connect to redis: v akka-bbb-apps/src/main/resources/application.conf - - akka-bbb-fsesl/src/main/resources/application.conf + v akka-bbb-fsesl/src/main/resources/application.conf v akka-bbb-transcode/src/main/resources/application.conf v bbb-webhooks/config_local.coffee.example v bigbluebutton-html5/private/config/settings-production.json @@ -63,9 +74,52 @@ docker exec -ti redis redis-cli monitor - remove FileAppender from bigbluebutton-web/grails-app/conf/logback.xml - set kurentoUrl on labs/bbb-webrtc-sfu/config/default.example.yml to ws://kurento/kurento - recordings -- reverse proxy using traefik +v reverse proxy using traefik (used nginx instead) - docker composer - UDP ports - generate dhparam - configure kurento public IP on bbb-webrtc-sfu - use config library to load the process.env automatically as it is on bbb-webrtc-sfu +- configure custom params on the html5 client +- configure udp ports on coturn +- configure udp ports on kms +- configure udp ports on freeswitch +- explore using stunclient stun.l.google.com 19302 | grep 'Mapped address' | cut -d':' -f2 | sed 's/[[:blank:]]//g' to figure out the public IP +- syncookies when using ufw + +Last minute notes: + +docker run --rm --name kurento --net host -d kurento +docker run --rm --name mongo -d mongo:3.4 +docker run --rm --name redis -d redis +docker run --rm --name coturn --net host -d kurento/coturn +# docker run --rm --name bbb-webrtc-sfu -p 3008:3008 --link redis --link kurento --link bbb-transcode -e KURENTO_IP=206.189.162.193 -e KURENTO_URL=ws://kurento:8888/kurento -e TRANSCODE_IP=bbb-transcode -e REDIS_HOST=redis -d bbb-webrtc-sfu +docker run --rm --name bbb-webrtc-sfu -p 3008:3008 --link redis --link bbb-transcode -e KURENTO_IP=206.189.162.193 -e KURENTO_URL=ws://felipe-docker.mconf.com:8888/kurento -e TRANSCODE_IP=bbb-transcode -e REDIS_HOST=redis -d bbb-webrtc-sfu + + + +docker run --rm --name haveged --privileged -d harbur/haveged +# docker run --rm --name kurento -d kurento/kurento-media-server +# docker run --rm --name kurento --net host -d kurento/kurento-media-server +docker run --rm --name kurento --net host -d kurento + +docker run --rm --name bbb-html5 --link mongo --link redis -e MONGO_URL=mongodb://mongo/bbbhtml5 -e METEOR_SETTINGS="$(cat private/config/settings-production.json)" -e REDIS_HOST=redis -e ROOT_URL=http://127.0.0.1/html5client -d bbb-html5 +docker run --rm --name bbb-webhooks --link redis -e REDIS_HOST=redis -d bbb-webhooks +docker run --rm --name bbb-apps-akka --link redis -e REDIS_HOST=redis -d bbb-apps-akka +docker run --rm --name bbb-transcode --link redis -e REDIS_HOST=redis -d bbb-transcode +docker run --rm --name bbb-web --link redis -e REDIS_HOST=redis -e SERVER_URL=https://felipe-docker.mconf.com -d bbb-web +docker run --rm --name greenlight -v $(pwd)/db/production:/usr/src/app/db/production --env-file greenlight.env -d bigbluebutton/greenlight +docker run --rm --name bbb-freeswitch -d bbb-freeswitch +docker run --rm --name bbb-fsesl-akka --link redis --link bbb-freeswitch -e REDIS_HOST=redis -e ESL_HOST=freeswitch -d bbb-fsesl-akka +docker run --rm --name libreoffice -p 8100:8100 -d libreoffice + +docker run --rm --name certbot -p 80:80 -v ~/certs:/etc/letsencrypt -it certbot/certbot certonly --non-interactive --register-unsafely-without-email --agree-tos --expand --domain felipe-docker.mconf.com --webroot -w /var/www/bigbluebutton-default/ +docker run --rm --name certbot -p 80:80 -v ~/certs:/etc/letsencrypt -it certbot/certbot certonly --non-interactive --register-unsafely-without-email --agree-tos --expand --domain felipe-docker.mconf.com --standalone + +openssl dhparam -out /root/dhp-2048.pem 2048 + +docker run --rm --name nginx --link bbb-webhooks --link bbb-web --link bbb-html5 --link bbb-webrtc-sfu --link greenlight -p 80:80 -p 443:443 -v ~/certs:/etc/letsencrypt -v $(pwd)/dhp-2048.pem:/etc/nginx/ssl/dhp-2048.pem -v $(pwd)/nginx.conf:/etc/nginx/nginx.conf -v $(pwd)/bigbluebutton-client/resources/config.xml.template:/var/www/bigbluebutton/client/conf/config.xml -d nginx + +docker exec -ti bbb-web cat webapps/bigbluebutton/WEB-INF/classes/bigbluebutton.properties | grep '^securitySalt=' | cut -d'=' -f2 +docker exec -ti redis redis-cli monitor + diff --git a/akka-bbb-apps/.dockerignore b/akka-bbb-apps/.dockerignore new file mode 100644 index 0000000000000000000000000000000000000000..c9c56767351f2752f2fad6e75af920655d3efa8d --- /dev/null +++ b/akka-bbb-apps/.dockerignore @@ -0,0 +1,2 @@ +Dockerfile + diff --git a/akka-bbb-apps/Dockerfile b/akka-bbb-apps/Dockerfile index 6f1ba3984b3d2233b7318914b98c0a7a9ad62409..003229be0f57a87fd8ef9d105b91db56b28911e2 100644 --- a/akka-bbb-apps/Dockerfile +++ b/akka-bbb-apps/Dockerfile @@ -1,23 +1,31 @@ -FROM sbt:0.13.8 +FROM bbb-common-message AS builder -ARG COMMON_VERSION +ARG COMMON_VERSION=0.0.1-SNAPSHOT -COPY ./bbb-common-message /bbb-common-message - -RUN cd /bbb-common-message \ - && sed -i "s|\(version := \)\".*|\1\"$COMMON_VERSION\"|g" build.sbt \ - && echo 'publishTo := Some(Resolver.file("file", new File(Path.userHome.absolutePath+"/.m2/repository")))' | tee -a build.sbt \ - && sbt compile \ - && sbt publishLocal - -COPY ./akka-bbb-apps /source +COPY . /source RUN cd /source \ - && find -name build.gradle -exec sed -i "s|\(.*org.bigbluebutton.*bbb-common-message[^:]*\):.*|\1:$COMMON_VERSION'|g" {} \; \ && find -name build.sbt -exec sed -i "s|\(.*org.bigbluebutton.*bbb-common-message[^\"]*\"[ ]*%[ ]*\)\"[^\"]*\"\(.*\)|\1\"$COMMON_VERSION\"\2|g" {} \; \ && sbt compile -WORKDIR /source +RUN apt-get update \ + && apt-get -y install fakeroot + +RUN cd /source \ + && sbt debian:packageBin + +# FROM ubuntu:16.04 +FROM openjdk:8-jre-slim-stretch + +COPY --from=builder /source/target/*.deb /root/ + +RUN dpkg -i /root/*.deb + +#RUN dpkg -i /root/*.deb || true \ +# && apt-get update \ +# && apt-get -y -f install + +CMD ["/usr/share/bbb-apps-akka/bin/bbb-apps-akka"] -CMD ["sbt", "run"] +# CMD ["sbt", "run"] diff --git a/bbb-lti/.dockerignore b/bbb-lti/.dockerignore new file mode 100644 index 0000000000000000000000000000000000000000..94143827ed065ca0d7d5be1b765d255c5c32cd9a --- /dev/null +++ b/bbb-lti/.dockerignore @@ -0,0 +1 @@ +Dockerfile diff --git a/bbb-lti/Dockerfile b/bbb-lti/Dockerfile new file mode 100644 index 0000000000000000000000000000000000000000..132e1c75d7a09dcfddc2ece248fd4d35ed4ef909 --- /dev/null +++ b/bbb-lti/Dockerfile @@ -0,0 +1,53 @@ +FROM java:8-jdk AS builder + +RUN mkdir -p /root/tools \ + && cd /root/tools \ + && wget http://services.gradle.org/distributions/gradle-2.12-bin.zip \ + && unzip gradle-2.12-bin.zip \ + && ln -s gradle-2.12 gradle + +RUN mkdir -p /root/tools \ + && cd /root/tools \ + && wget https://github.com/grails/grails-core/releases/download/v2.5.2/grails-2.5.2.zip \ + && unzip grails-2.5.2.zip \ + && ln -s grails-2.5.2 grails + +ENV PATH="/root/tools/gradle/bin:/root/tools/grails/bin:${PATH}" + +COPY . /source + +# build with: +# docker build -t mconftec/bbb-lti --build-arg title=Mconf --build-arg description='Single Sign On into Mconf' --build-arg vendor_code=mconf --build-arg vendor_name=Mconf --build-arg vendor_description='Mconf web conferencing' --build-arg vendor_url=https://mconf.com . + +ARG title=BigBlueButton +ARG description='Single Sign On into BigBlueButton' +ARG vendor_code=bigbluebutton +ARG vendor_name=BigBlueButton +ARG vendor_description='Open source web conferencing system for distance learning.' +ARG vendor_url=http://www.bigbluebutton.org/ + +RUN cd /source \ + && sed -i "s|\(<blti:title>\)[^<]*|\1$title|g" grails-app/controllers/org/bigbluebutton/ToolController.groovy \ + && sed -i "s|\(<blti:description>\)[^<]*|\1$description|g" grails-app/controllers/org/bigbluebutton/ToolController.groovy \ + && sed -i "s|\(<lticp:code>\)[^<]*|\1$vendor_code|g" grails-app/controllers/org/bigbluebutton/ToolController.groovy \ + && sed -i "s|\(<lticp:name>\)[^<]*|\1$vendor_name|g" grails-app/controllers/org/bigbluebutton/ToolController.groovy \ + && sed -i "s|\(<lticp:description>\)[^<]*|\1$vendor_description|g" grails-app/controllers/org/bigbluebutton/ToolController.groovy \ + && sed -i "s|\(<lticp:url>\)[^<]*|\1$vendor_url|g" grails-app/controllers/org/bigbluebutton/ToolController.groovy \ + && grails war + +FROM tomcat:7-jre8 + +WORKDIR $CATALINA_HOME + +# clean default webapps +RUN rm -r webapps/* + +COPY --from=builder /source/target/lti-*.war webapps/lti.war + +RUN unzip -q webapps/lti.war -d webapps/lti \ + && rm webapps/lti.war + +COPY entrypoint.sh . + +CMD ["./entrypoint.sh"] + diff --git a/bbb-lti/entrypoint.sh b/bbb-lti/entrypoint.sh new file mode 100755 index 0000000000000000000000000000000000000000..608af0aa7ad42fa92ec1d1b73f85021484974b78 --- /dev/null +++ b/bbb-lti/entrypoint.sh @@ -0,0 +1,7 @@ +#!/bin/bash -xe + +export JAVA_OPTS="$JAVA_OPTS -Djava.security.egd=file:/dev/./urandom -DbigbluebuttonSalt=$BIGBLUEBUTTON_SHARED_SECRET -DbigbluebuttonURL=$BIGBLUEBUTTON_URL -DltiEndPoint=$LTI_ENDPOINT -DltiConsumers=$LTI_CONSUMERS -DltiAllRecordedByDefault=$RECORDED_BY_DEFAULT" +sed -i "s|^securerandom\.source=.*|securerandom.source=file:/dev/./urandom|g" $JAVA_HOME/lib/security/java.security + +catalina.sh run + diff --git a/bbb-lti/grails-app/i18n/messages.properties b/bbb-lti/grails-app/i18n/messages.properties index 4b708fbecba231e618ff510beff21645a3ccdddd..dbf3ab604fd02c8dd8f49ea52b413b84f7fc0a91 100644 --- a/bbb-lti/grails-app/i18n/messages.properties +++ b/bbb-lti/grails-app/i18n/messages.properties @@ -19,12 +19,12 @@ # The welcome.header can be static, however if you want the name of the activity (meeting) to be injected use {0} as part of the text # {1} can be used to inject the name of the course bigbluebutton.welcome.header=Welcome to <b>{0}</b>! -bigbluebutton.welcome.footer=To understand how BigBlueButton works see our <a href=\"event:http://www.bigbluebutton.org/content/videos\"><u>tutorial videos</u></a>.<br><br>To join the audio bridge click the headset icon (upper-left hand corner). <b>Please use a headset to avoid causing noise for others. +bigbluebutton.welcome.footer=To join the audio bridge click the headset icon (upper-left hand corner). <b>Please use a headset to avoid causing noise for others. bigbluebutton.welcome.record=This meeting is being recorded bigbluebutton.welcome.duration=The maximum duration for this meeting is {0} minutes -tool.view.app=BigBlueButton -tool.view.title=BigBlueButton LTI Interface +tool.view.app=Mconf +tool.view.title=Mconf LTI Interface tool.view.join=Join Meeting tool.view.recording=Recording tool.view.recording.format.presentation=presentation diff --git a/bbb-lti/grails-app/i18n/messages_es.properties b/bbb-lti/grails-app/i18n/messages_es.properties index 2513f516b2906e9dec726a59a4225b176dd32311..0d47b069eed58a9f635f6a381eb064ea623d71e8 100644 --- a/bbb-lti/grails-app/i18n/messages_es.properties +++ b/bbb-lti/grails-app/i18n/messages_es.properties @@ -17,12 +17,12 @@ # bigbluebutton.welcome.header=Bienvenido a <b>{0}</b>! -bigbluebutton.welcome.footer=Para entender como funciona BigBlueButton consulte estos <a href=\"event:http://www.bigbluebutton.org/content/videos\"><u>videos tutoriales</u></a>.<br><br>Para activar el audio haga click en el icono de auricular (equina superior izquierda). <b>Por favor utilice auricular para evitar causar ruido. +bigbluebutton.welcome.footer=Para activar el audio haga click en el icono de auricular (equina superior izquierda). <b>Por favor utilice auricular para evitar causar ruido. bigbluebutton.welcome.record=Esta sesión esta siendo grabada bigbluebutton.welcome.duration=La duración maxima para esta sesión es de {0} minutos -tool.view.app=BigBlueButton -tool.view.title=Interface LTI para BigBlueButton +tool.view.app=Mconf +tool.view.title=Interface LTI para Mconf tool.view.join=Ingresar a la sesión tool.view.recording=Grabación tool.view.recording.format.presentation=presentación diff --git a/bbb-lti/grails-app/i18n/messages_fr.properties b/bbb-lti/grails-app/i18n/messages_fr.properties index a25b69bf01283a26867cecec4706e18ef265e11a..3c38fb490b684a6fb3f0f2322b086fae052749dc 100644 --- a/bbb-lti/grails-app/i18n/messages_fr.properties +++ b/bbb-lti/grails-app/i18n/messages_fr.properties @@ -17,10 +17,10 @@ # bigbluebutton.welcome.header=<br>Bienvenue au <b>{0}</b>!<br> -bigbluebutton.welcome.footer=<br>Pour comprendre comment fonctionne BigBlueButton, consultez les <a href=\"event:http://www.bigbluebutton.org/content/videos\"><u>didacticiels vidéo</u></a>.<br><br>Pour activer l'audio cliquez sur l'icône du casque à écouteurs (coin supérieur gauche). <b>S'il vous pla�t utiliser le casque pour éviter de causer du bruit.</b> +bigbluebutton.welcome.footer=<br>Pour activer l'audio cliquez sur l'icône du casque à écouteurs (coin supérieur gauche). <b>S'il vous pla�t utiliser le casque pour éviter de causer du bruit.</b> -tool.view.app=BigBlueButton -tool.view.title=LTI Interface pour BigBlueButton +tool.view.app=Mconf +tool.view.title=LTI Interface pour Mconf tool.view.join=Saisie de la réunion tool.view.recording=Enregistrement tool.view.recording.format.presentation=presentation diff --git a/bbb-lti/grails-app/i18n/messages_pt.properties b/bbb-lti/grails-app/i18n/messages_pt.properties new file mode 100644 index 0000000000000000000000000000000000000000..d39a3650fa8cad15f357eee9dbf964720a312957 --- /dev/null +++ b/bbb-lti/grails-app/i18n/messages_pt.properties @@ -0,0 +1,48 @@ +# +# BigBlueButton open source conferencing system - http://www.bigbluebutton.org/ +# +# Copyright (c) 2012 BigBlueButton Inc. and by respective authors (see below). +# +# This program is free software; you can redistribute it and/or modify it under the +# terms of the GNU Lesser General Public License as published by the Free Software +# Foundation; either version 3.0 of the License, or (at your option) any later +# version. +# +# BigBlueButton is distributed in the hope that it will be useful, but WITHOUT ANY +# WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A +# PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public License along +# with BigBlueButton; if not, see <http://www.gnu.org/licenses/>. +# + +# The welcome.header can be static, however if you want the name of the activity (meeting) to be injected use {0} as part of the text +# {1} can be used to inject the name of the course +bigbluebutton.welcome.header=Bem-vindo à sala <b>{0}</b>! +bigbluebutton.welcome.footer=Para habilitar o áudio, clique no botão do headset (no canto superior esquerdo). <b>Para uma melhor experiência, utilize sempre que possível um headset e conecte na rede cabeada. +bigbluebutton.welcome.record=Esta sessão está sendo gravada +bigbluebutton.welcome.duration=A duração máxima desta sessão é de {0} minutos + +tool.view.app=Mconf +tool.view.title=Interface LTI do Mconf +tool.view.join=Entrar na sala +tool.view.recording=Gravação +tool.view.recording.format.presentation=apresentação +tool.view.recording.format.video=vídeo +tool.view.recording.delete.confirmation=Você tem certeza que deseja remover permanentemente esta gravação? +tool.view.recording.delete.confirmation.warning=Aviso +tool.view.recording.delete.confirmation.yes=Sim +tool.view.recording.delete.confirmation.no=Não +tool.view.recording.publish=Publicar +tool.view.recording.unpublish=Despublicar +tool.view.recording.delete=Remover +tool.view.activity=Atividade +tool.view.description=Descrição +tool.view.preview=Preview +tool.view.date=Data +tool.view.duration=Duração +tool.view.actions=Ações +tool.view.dateFormat=dd/mm/yyyy HH:mm:ss Z + +tool.error.general=Conexão não pode ser estabelecida. + diff --git a/bbb-webhooks/config/custom-environment-variables.yml b/bbb-webhooks/config/custom-environment-variables.yml new file mode 100644 index 0000000000000000000000000000000000000000..eb173affbbf5bdfc008d6152691a4bb031b7b193 --- /dev/null +++ b/bbb-webhooks/config/custom-environment-variables.yml @@ -0,0 +1,4 @@ +config: + redis: + host: REDIS_HOST + diff --git a/bigbluebutton-html5/.dockerignore b/bigbluebutton-html5/.dockerignore new file mode 100644 index 0000000000000000000000000000000000000000..a1bdef1424c74f999b65bc7dfe699cfc8ff996cb --- /dev/null +++ b/bigbluebutton-html5/.dockerignore @@ -0,0 +1,3 @@ +private/config/settings-production.json +Dockerfile +Dockerfile.dev diff --git a/bigbluebutton-html5/Dockerfile b/bigbluebutton-html5/Dockerfile index 089f803161fad30e7939e22ac5e4408f5f6d615e..94d070ac512432630f086ba221713ce4337b0570 100644 --- a/bigbluebutton-html5/Dockerfile +++ b/bigbluebutton-html5/Dockerfile @@ -1,12 +1,13 @@ FROM node:8 -ADD . /source +COPY . /source RUN set -x \ && curl -sL https://install.meteor.com | sed s/--progress-bar/-sL/g | /bin/sh \ && useradd -m -G users -s /bin/bash meteor \ - && mkdir /app \ - && chown -R meteor:meteor /source \ + && chown -R meteor:meteor /source + +RUN mkdir /app \ && chown -R meteor:meteor /app USER meteor @@ -30,3 +31,4 @@ ENV MONGO_URL=mongodb://mongo:27017/html5client \ EXPOSE 3000 CMD ["node", "main.js"] + diff --git a/bigbluebutton-html5/Dockerfile.dev b/bigbluebutton-html5/Dockerfile.dev new file mode 100644 index 0000000000000000000000000000000000000000..692c200be719aca865919535210674ff871c76ee --- /dev/null +++ b/bigbluebutton-html5/Dockerfile.dev @@ -0,0 +1,24 @@ +FROM node:8 + +COPY . /source + +RUN set -x \ + && curl -sL https://install.meteor.com | sed s/--progress-bar/-sL/g | /bin/sh \ + && useradd -m -G users -s /bin/bash meteor \ + && chown -R meteor:meteor /source + +USER meteor + +RUN cd /source \ + && meteor npm install + +WORKDIR /source + +ENV MONGO_URL=mongodb://mongo:27017/html5client \ + PORT=3000 \ + ROOT_URL=http://localhost:3000 + +EXPOSE 3000 + +CMD ["npm", "start"] + diff --git a/bigbluebutton-web/.dockerignore b/bigbluebutton-web/.dockerignore new file mode 100644 index 0000000000000000000000000000000000000000..94143827ed065ca0d7d5be1b765d255c5c32cd9a --- /dev/null +++ b/bigbluebutton-web/.dockerignore @@ -0,0 +1 @@ +Dockerfile diff --git a/bigbluebutton-web/Dockerfile b/bigbluebutton-web/Dockerfile index a4638ff3e5b10dda2e0ddd81eb9f921729c2ea87..74ec97ba0236aceed10947188222365d86b68e05 100644 --- a/bigbluebutton-web/Dockerfile +++ b/bigbluebutton-web/Dockerfile @@ -14,7 +14,7 @@ RUN mkdir -p /root/tools \ ENV PATH="/root/tools/gradle/bin:/root/tools/grails/bin:${PATH}" -ARG COMMON_VERSION +ARG COMMON_VERSION=0.0.1-SNAPSHOT COPY . /source @@ -30,17 +30,23 @@ FROM tomcat:7-jre8 WORKDIR $CATALINA_HOME -COPY --from=builder /source/target/bigbluebutton-0.9.0.war webapps/bigbluebutton.war - -COPY docker_wrapper.sh . - RUN apt-get update \ - && apt-get -y install imagemagick xpdf-utils libreoffice ttf-liberation psmisc fonts-crosextra-carlito fonts-crosextra-caladea + && apt-get -y install imagemagick xpdf-utils libreoffice ttf-liberation psmisc fonts-crosextra-carlito fonts-crosextra-caladea unzip RUN echo "deb http://ubuntu.bigbluebutton.org/xenial-200 bigbluebutton-xenial main " | tee /etc/apt/sources.list.d/bigbluebutton.list \ && wget http://ubuntu.bigbluebutton.org/repo/bigbluebutton.asc -O- | apt-key add - \ && apt-get update \ && apt-get -y install bbb-swftools -CMD [ "./docker_wrapper.sh" ] +# clean default webapps +RUN rm -r webapps/* + +COPY --from=builder /source/target/bigbluebutton-0.9.0.war webapps/bigbluebutton.war + +RUN unzip -q webapps/bigbluebutton.war -d webapps/bigbluebutton \ + && rm webapps/bigbluebutton.war + +COPY entrypoint.sh . + +CMD ["./entrypoint.sh"] diff --git a/bigbluebutton-web/docker_wrapper.sh b/bigbluebutton-web/docker_wrapper.sh deleted file mode 100755 index 8bdd41bdd4c6ced956c11c7b3d2a86df2762d0b4..0000000000000000000000000000000000000000 --- a/bigbluebutton-web/docker_wrapper.sh +++ /dev/null @@ -1,10 +0,0 @@ -#!/bin/bash -e - -pushd . -cd webapps/ -jar xvf bigbluebutton.war -sed -i 's|^bigbluebutton\.web\.serverURL.*|bigbluebutton.web.serverURL=https://$SERVER_URL|g' bigbluebutton/WEB-INF/classes/bigbluebutton.properties -popd - -./bin/catalina.sh run - diff --git a/bigbluebutton-web/entrypoint.sh b/bigbluebutton-web/entrypoint.sh new file mode 100755 index 0000000000000000000000000000000000000000..02092041cd399897998daa0828595d7e1640b29c --- /dev/null +++ b/bigbluebutton-web/entrypoint.sh @@ -0,0 +1,18 @@ +#!/bin/bash -xe + +mkdir -p /var/bigbluebutton/recording/raw +mkdir -p /var/bigbluebutton/recording/process +mkdir -p /var/bigbluebutton/recording/publish +mkdir -p /var/bigbluebutton/recording/status/recorded +mkdir -p /var/bigbluebutton/recording/status/archived +mkdir -p /var/bigbluebutton/recording/status/processed +mkdir -p /var/bigbluebutton/recording/status/sanity +mkdir -p /var/bigbluebutton/published +mkdir -p /var/bigbluebutton/deleted +mkdir -p /var/bigbluebutton/unpublished + +export JAVA_OPTS="$JAVA_OPTS -Djava.security.egd=file:/dev/./urandom -DsecuritySalt=$SHARED_SECRET -Dredis.host=redis -Dbigbluebutton.web.serverURL=https://$SERVER_DOMAIN" +sed -i "s|^securerandom\.source=.*|securerandom.source=file:/dev/./urandom|g" $JAVA_HOME/lib/security/java.security + +catalina.sh run + diff --git a/labs/docker/docker-compose.yml b/labs/docker/docker-compose.yml new file mode 100644 index 0000000000000000000000000000000000000000..1dbfdfcef9dfd8ac37d4cd81f5f13a881dff7b98 --- /dev/null +++ b/labs/docker/docker-compose.yml @@ -0,0 +1,102 @@ +version: '2' + +services: +# nginx-dhp: +# image: nginx-dhp +# volumes: +# - config-nginx-dhp:/data + +# nginx-ssl: +# image: certbot/certbot +# ports: +# - 80:80 +# volumes: +# - config-nginx-ssl:/etc/letsencrypt +# command: certonly --non-interactive --register-unsafely-without-email --agree-tos --expand --domain ${SERVER_DOMAIN} --standalone + +# mongo: +# image: mongo:3.4 +# restart: unless-stopped + + redis: + image: redis + restart: unless-stopped + volumes: + - recordings-redis:/data + + bbb-webhooks: + image: bbb-webhooks + restart: unless-stopped + links: + - redis + environment: + REDIS_HOST: redis + +# coturn: +# image: kurento/coturn +# restart: unless-stopped +# network_mode: host + +# kurento: +# image: kurento +# restart: unless-stopped +# network_mode: host + +# bbb-apps-akka: +# image: bbb-apps-akka +# restart: unless-stopped +# links: +# - redis +# environment: +# JAVA_OPTS: -Dredis.host=redis + +# bbb-web: +# image: bbb-web +# restart: unless-stopped +# links: +# - redis +# volumes: +# - recordings-storage:/var/bigbluebutton +# environment: +# SERVER_DOMAIN: ${SERVER_DOMAIN} +# SHARED_SECRET: ${SHARED_SECRET} + +# greenlight-env: +# image: bigbluebutton/greenlight +# volumes: +# - config-greenlight:/data +# command: rake secret > /data/env + + greenlight: + image: bigbluebutton/greenlight + restart: unless-stopped + volumes: + - db-greenlight:/usr/src/app/db/production + + nginx: + image: nginx + restart: unless-stopped + links: + - bbb-webhooks + - bbb-web + - bbb-html5 + - bbb-webrtc-sfu + - greenlight + ports: + - 80:80 + - 443:443 + volumes: + - config-nginx-ssl:/etc/letsencrypt + - config-nginx-dhp/dhp-2048.pem:/etc/nginx/ssl/dhp-2048.pem + + + +docker run --rm --name nginx --link bbb-webhooks --link bbb-web --link bbb-html5 --link bbb-webrtc-sfu --link greenlight -p 80:80 -p 443:443 -v ~/certs:/etc/letsencrypt -v $(pwd)/dhp-2048.pem:/etc/nginx/ssl/dhp-2048.pem -v $(pwd)/nginx.conf:/etc/nginx/nginx.conf -v $(pwd)/bigbluebutton-client/resources/config.xml.template:/var/www/bigbluebutton/client/conf/config.xml -d nginx + +volumes: + config-nginx-dhp: + config-nginx-ssl: + config-greenlight: + recordings-redis: + recordings-storage: + db-greenlight: diff --git a/labs/docker/greenlight/db/production/production.sqlite3 b/labs/docker/greenlight/db/production/production.sqlite3 new file mode 100644 index 0000000000000000000000000000000000000000..87e8ce3b4cf9ea1fbafb8613dbdb8384e11eaeb9 Binary files /dev/null and b/labs/docker/greenlight/db/production/production.sqlite3 differ diff --git a/labs/docker/greenlight/greenlight.env b/labs/docker/greenlight/greenlight.env new file mode 100644 index 0000000000000000000000000000000000000000..830bb1ddad041bbe0921f0e0581ec11f82cefcae --- /dev/null +++ b/labs/docker/greenlight/greenlight.env @@ -0,0 +1,150 @@ +# This is a sample of the environment variables you will need +# To use, copy this file to .env `cp sample.env .env` + +# Create a secret key for rails +# +# You can generate a secure one through the Greenlight docker image +# with with the command +# +# docker run --rm bigbluebutton/greenlight rake secret +# +SECRET_KEY_BASE=a8b7f914b8323db980756414b6eb7b9825eb84befbc0bd9b9beeb2e84a89f3e959e198149150649b0b101eaf323e79250f3f5662db185c35562ef1a3e12cdabc + +# For either developent or production + +# Enter credentials for your BigBlueButton Server +# +# The endpoint and secret from your bigbluebutton server. To get these values, run +# the following command on your BigBlueButton server +# +# bbb-conf --secret +# +# and uncomment the following two variables +BIGBLUEBUTTON_ENDPOINT=https://felipe-docker.mconf.com/bigbluebutton/ +BIGBLUEBUTTON_SECRET=2ff5336294114f9ee7ff4596203f2a53 + +# Set default client (optional) +# +# By default, GreenLight will join users to a BigBlueButton session using the Flash +# client. By setting USE_HTML5_BY_DEFAULT to true, you can configure GreenLight to +# use the HTML5 client by default. GreenLight will only use the default for +# non-authenticated users. Users who have authenticated are able to set their +# prefered client under preferences. Also note that if the HTML5 client is not +# running on a BigBlueButton server, all clients will be joined using Flash +# regardless on any settings. +USE_HTML5_BY_DEFAULT=true + +# Twitter Login Provider (optional) +# +# You will need to register the app at https://apps.twitter.com/ +# For the callback URL use 'http://<your hostname:port>/auth/twitter/callback' +# Once registered copy the ID and Secret here +# +TWITTER_ID= +TWITTER_SECRET= + +# Google Login Provider (optional) +# +# You will need to register for at https://console.developers.google.com/apis/credentials +# Select Oauth client ID -> web application +# For the callback URL use 'http://<your hostname:port>/auth/google/callback' +# Once registered copy the ID and Secret here +# +# The GOOGLE_OAUTH2_HD variable is used to limit sign-in to a particular Google Apps hosted domain. This +# can be a string such as, 'domain.com'. If left blank, GreenLight will allow sign-in from all Google Apps hosted +# domains. +# +GOOGLE_OAUTH2_ID= +GOOGLE_OAUTH2_SECRET= +GOOGLE_OAUTH2_HD= + +# LDAP Login Provider (optional) +# +# You can enable LDAP authentication by providing values for the variables below. +# For information about setting up LDAP, see: +# http://docs.bigbluebutton.org/install/green-light.html#ldap-oauth +# +LDAP_SERVER= +LDAP_PORT= +LDAP_METHOD= +LDAP_UID= +LDAP_BASE= +LDAP_BIND_DN= +LDAP_PASSWORD= + +# If "true", GreenLight will register a webhook callback for each meeting +# created. This callback is called for all events that happen in the meeting, +# including the processing of its recording. These events are used to update +# the web page dynamically as things happen in the server. +# If not "true", the application will add a metadata to the meetings with this same +# callback URL. Scripts can then be added to BigBlueButton to call this callback +# URL and send specific events to GreenLight (e.g. a post publish script to warn +# the application when recordings are done). +# GREENLIGHT_USE_WEBHOOKS=true + +# Enable uploading to Youtube (optional) +# +# When this is enabled, users will be able to directly upload their recordings +# to Youtube. If you plan to enable this, you should follow the steps outlined +# in our docs for setting up the Youtube data API. +# +# http://docs.bigbluebutton.org/install/green-light.html#8-enabling-uploading-to-youtube-optional +# +ENABLE_YOUTUBE_UPLOADING=false + +# Slack Integration (optional) +# +# You will need to register an incoming-webhook for your slack channel +# in order for GreenLight to post to it. You can do this by going +# to https://slack.com/apps/A0F7XDUAZ-incoming-webhooks, selecting your +# team and then selecting "Add Incoming WebHooks integration" on the +# desired channel. You will then need to paste the webhook below. +# +SLACK_WEBHOOK= +SLACK_CHANNEL= + +# Landing Background (optional) +# +# Supply a URL to an image to change the landing background. If no +# URL is provided GreenLight will use a default image. If you +# supply a path that does not lead to an image, no landing image +# will appear. +# +LANDING_BACKGROUND= + +# SMTP Mailer (optional) +# +GREENLIGHT_MAIL_NOTIFICATIONS=true +# In the format [localhost.localdomain] +GREENLIGHT_DOMAIN=localhost-lxc.org +SMTP_FROM=youremail@gmail.com +SMTP_SERVER=smtp.gmail.com +SMTP_PORT=587 +SMTP_DOMAIN=gmail.com +SMTP_USERNAME=youremail@gmail.com +SMTP_PASSWORD=yourpassword +# SMTP_TLS=false +# SMTP_AUTH=login +# SMTP_STARTTLS_AUTO=true + +# Enable QR Code generation (optional) +# +# When this is enabled, users will be able to generate a QR code for direct access +# to a meeting room that can be shared as the URL link. +# +ENABLE_QRCODE_GENERATION=false + + +# Prefix for the application's root URL +# Useful for deploying the application to a subdirectory +# +# default is '/b' (recommended) +# +# RELATIVE_URL_ROOT=/b + +# Uncomment and set to 'true' to only allow users to create meetings when authenticated. +# Unauthenticated users are still able to join meetings through invites. +# DISABLE_GUEST_ACCESS=false + +# Comment this out to send logs to STDOUT in production instead of log/production.log . +DISABLE_RAILS_LOG_TO_STDOUT=true diff --git a/labs/docker/kurento/Dockerfile b/labs/docker/kurento/Dockerfile new file mode 100644 index 0000000000000000000000000000000000000000..635c347fd2d95b0196325a025391dcf8a161567e --- /dev/null +++ b/labs/docker/kurento/Dockerfile @@ -0,0 +1,28 @@ +FROM ubuntu:16.04 + +RUN apt-get update \ + && apt-get -y dist-upgrade \ + && apt-get install -y software-properties-common curl wget apt-transport-https + +RUN wget https://ubuntu.bigbluebutton.org/repo/bigbluebutton.asc -O- | apt-key add - \ + && add-apt-repository "deb https://ubuntu.bigbluebutton.org/xenial-200-dev bigbluebutton-xenial main" \ + && apt-get update \ + && apt-get -y install kurento-media-server \ + && apt-get clean \ + && rm -rf /var/lib/apt/lists/* + +RUN apt-get update \ + && apt-get install -y bzip2 \ + && apt-get install -y --download-only openh264-gst-plugins-bad-1.5 + +EXPOSE 8888 + +COPY ./entrypoint.sh /entrypoint.sh +COPY ./healthchecker.sh /healthchecker.sh + +HEALTHCHECK --start-period=15s --interval=30s --timeout=3s --retries=1 CMD /healthchecker.sh + +ENV GST_DEBUG=Kurento*:5 + +ENTRYPOINT ["/entrypoint.sh"] + diff --git a/labs/docker/kurento/entrypoint.sh b/labs/docker/kurento/entrypoint.sh new file mode 100755 index 0000000000000000000000000000000000000000..cacc90dc626919f7a04cd14526eb452d94a278c8 --- /dev/null +++ b/labs/docker/kurento/entrypoint.sh @@ -0,0 +1,20 @@ +#!/bin/bash -x +set -e + +apt-get install -y openh264-gst-plugins-bad-1.5 + +if [ -n "$KMS_TURN_URL" ]; then + echo "turnURL=$KMS_TURN_URL" > /etc/kurento/modules/kurento/WebRtcEndpoint.conf.ini +fi + +if [ -n "$KMS_STUN_IP" -a -n "$KMS_STUN_PORT" ]; then + # Generate WebRtcEndpoint configuration + echo "stunServerAddress=$KMS_STUN_IP" > /etc/kurento/modules/kurento/WebRtcEndpoint.conf.ini + echo "stunServerPort=$KMS_STUN_PORT" >> /etc/kurento/modules/kurento/WebRtcEndpoint.conf.ini +fi + +# Remove ipv6 local loop until ipv6 is supported +cat /etc/hosts | sed '/::1/d' | tee /etc/hosts > /dev/null + +exec /usr/bin/kurento-media-server "$@" + diff --git a/labs/docker/kurento/healthchecker.sh b/labs/docker/kurento/healthchecker.sh new file mode 100755 index 0000000000000000000000000000000000000000..c7f6ce82faf2c3667e2ce65030963ab02bff83c9 --- /dev/null +++ b/labs/docker/kurento/healthchecker.sh @@ -0,0 +1,3 @@ +#!/bin/bash + +[[ "$(curl -w '%{http_code}' -N -H "Connection: Upgrade" -H "Upgrade: websocket" -H "Host: 127.0.0.1:8888" -H "Origin: 127.0.0.1" http://127.0.0.1:8888/kurento)" == 500 ]] && exit 0 || exit 1 diff --git a/labs/docker/nginx-dhp/Dockerfile b/labs/docker/nginx-dhp/Dockerfile new file mode 100644 index 0000000000000000000000000000000000000000..f2e1bfddf1ab1bf7e39be8f1549ba80e7ae47ea9 --- /dev/null +++ b/labs/docker/nginx-dhp/Dockerfile @@ -0,0 +1,8 @@ +FROM tannerfe/alpine-openssl + +WORKDIR /root + +COPY entrypoint.sh . + +CMD ["./entrypoint.sh"] + diff --git a/labs/docker/nginx-dhp/entrypoint.sh b/labs/docker/nginx-dhp/entrypoint.sh new file mode 100755 index 0000000000000000000000000000000000000000..63300a9b5fe20ed679ab53b79536d6a024cc5cba --- /dev/null +++ b/labs/docker/nginx-dhp/entrypoint.sh @@ -0,0 +1,6 @@ +#!/bin/sh -xe + +if [ ! -f /data/dhp-2048.pem ]; then + openssl dhparam -out /data/dhp-2048.pem 2048 +fi + diff --git a/labs/docker/nginx/Dockerfile b/labs/docker/nginx/Dockerfile new file mode 100644 index 0000000000000000000000000000000000000000..b36d8fa8cb12e96cae6666b6a9f498df48e9ae3f --- /dev/null +++ b/labs/docker/nginx/Dockerfile @@ -0,0 +1,6 @@ +FROM nginx + +COPY ./nginx.conf /etc/nginx/nginx.conf +COPY ./config.xml /var/www/bigbluebutton/client/conf/config.xml + + diff --git a/labs/docker/nginx/config.xml b/labs/docker/nginx/config.xml new file mode 100755 index 0000000000000000000000000000000000000000..084f76ef1bc6b4ee29eec2e4476ca92b947f6f02 --- /dev/null +++ b/labs/docker/nginx/config.xml @@ -0,0 +1,158 @@ +<?xml version="1.0" ?> +<config> + <localeversion suppressWarning="false">0.9.0</localeversion> + <version>VERSION</version> + <help url="http://HOST/help.html"/> + <javaTest url="http://HOST/testjava.html"/> + <porttest host="rtmp://HOST" application="video/portTest" timeout="10000"/> + <bwMon server="rtmp://HOST" application="video/bwTest"/> + <application uri="rtmp://HOST/bigbluebutton" host="http://HOST/bigbluebutton/api/enter"/> + <language userSelectionEnabled="true" rtlEnabled="false"/> + <skinning url="http://HOST/client/branding/css/V2Theme.css.swf?v=VERSION" /> + <branding logo="logos/logo.swf" copyright="© 2017 <u><a href="http://HOST/home.html" target="_blank">BigBlueButton Inc.</a></u> (build {0})" background="" toolbarColor="" showQuote="true"/> + <shortcutKeys showButton="true" /> + <browserVersions chrome="CHROME_VERSION" firefox="FIREFOX_VERSION" flash="FLASH_VERSION"/> + <layout showLogButton="false" defaultLayout="bbb.layout.name.defaultlayout" + showToolbar="true" showFooter="true" showMeetingName="true" showHelpButton="true" + showLogoutWindow="true" showLayoutTools="true" confirmLogout="true" showNetworkMonitor="false" + showRecordingNotification="true" logoutOnStopRecording="false" + askForFeedbackOnLogout="false"/> + <breakoutRooms enabled="true" record="false" privateChateEnabled="true"/> + <logging enabled="true" logTarget="trace" level="info" format="{dateUTC} {time} :: {name} :: [{logLevel}] {message}" uri="http://HOST/log" logPattern=".*"/> + <lock disableCam="false" disableMic="false" disablePrivateChat="false" + disablePublicChat="false" lockedLayout="false" lockOnJoin="true" lockOnJoinConfigurable="false"/> + + <modules> + + <module name="ChatModule" url="http://HOST/client/ChatModule.swf?v=VERSION" + uri="rtmp://HOST/bigbluebutton" + dependsOn="UsersModule" + privateEnabled="true" + fontSize="14" + baseTabIndex="801" + colorPickerIsVisible="false" + maxMessageLength="1024" + /> + + <module name="UsersModule" url="http://HOST/client/UsersModule.swf?v=VERSION" + uri="rtmp://HOST/bigbluebutton" + allowKickUser="true" + enableEmojiStatus="true" + enableSettingsButton="true" + enableGuestUI="false" + moderatorUnmute="true" + baseTabIndex="301" + /> + + <module name="ScreenshareModule" + url="http://HOST/client/ScreenshareModule.swf?v=VERSION" + uri="rtmp://HOST/screenshare" + showButton="true" + enablePause="true" + tryKurentoWebRTC="false" + tryWebRTCFirst="false" + chromeExtensionLink="" + chromeExtensionKey="" + baseTabIndex="201" + help="http://HOST/client/help/screenshare-help.html" + /> + + <module name="PhoneModule" url="http://HOST/client/PhoneModule.swf?v=VERSION" + uri="rtmp://HOST/sip" + dependsOn="UsersModule" + autoJoin="true" + listenOnlyMode="true" + forceListenOnly="false" + skipCheck="false" + showButton="true" + enabledEchoCancel="true" + useWebRTCIfAvailable="true" + showPhoneOption="false" + showWebRTCStats="false" + showWebRTCMOS="false" + echoTestApp="9196" + /> + + <module name="VideoconfModule" url="http://HOST/client/VideoconfModule.swf?v=VERSION" + uri="rtmp://HOST/video" + dependsOn="UsersModule" + baseTabIndex="401" + autoStart="false" + skipCamSettingsCheck="false" + showButton="true" + applyConvolutionFilter="false" + convolutionFilter="-1, 0, -1, 0, 6, 0, -1, 0, -1" + filterBias="0" + filterDivisor="4" + displayAvatar="false" + priorityRatio="0.67" + /> + + <module name="WhiteboardModule" url="http://HOST/client/WhiteboardModule.swf?v=VERSION" + uri="rtmp://HOST/bigbluebutton" + dependsOn="PresentModule" + baseTabIndex="601" + keepToolbarVisible="false" + /> + + <module name="PollingModule" url="http://HOST/client/PollingModule.swf?v=VERSION" + uri="rtmp://HOST/bigbluebutton" + dependsOn="PresentModule" + /> + + <module name="PresentModule" url="http://HOST/client/PresentModule.swf?v=VERSION" + uri="rtmp://HOST/bigbluebutton" + dependsOn="UsersModule" + host="http://HOST" + showPresentWindow="true" + showWindowControls="true" + openExternalFileUploadDialog="false" + baseTabIndex="501" + maxFileSize="30" + enableDownload="true" + /> + + <module name="CaptionModule" url="http://HOST/client/CaptionModule.swf?v=VERSION" + uri="rtmp://HOST/bigbluebutton" + dependsOn="UsersModule" + maxPasteLength="1024" + baseTabIndex="701" + /> + + <module name="LayoutModule" url="http://HOST/client/LayoutModule.swf?v=VERSION" + uri="rtmp://HOST/bigbluebutton" + layoutConfig="http://HOST/client/conf/layout.xml" + enableEdit="false" + /> + + <module name="SharedNotesModule" url="http://HOST/client/SharedNotesModule.swf?v=VERSION" + uri="rtmp://HOST/bigbluebutton" + dependsOn="UsersModule" + refreshDelay="500" + toolbarVisibleByDefault="false" + showToolbarButton="true" + fontSize="14" + maxMessageLength="5000" + maxNoteLength="10000" + enableDeleteNotes="false" + hideAdditionalNotes="false" + /> + +<!-- + <module name="NotesModule" url="http://HOST/client/NotesModule.swf?v=VERSION" + saveURL="http://HOST" + position="top-left" + /> + + <module name="BroadcastModule" url="http://HOST/client/BroadcastModule.swf?v=VERSION" + uri="rtmp://HOST/bigbluebutton" + streamsUri="http://HOST/streams.xml" + position="top-left" + showStreams="true" + autoPlay="false" + dependsOn="UsersModule" + /> +--> + + </modules> +</config> diff --git a/labs/docker/nginx/nginx.conf b/labs/docker/nginx/nginx.conf new file mode 100644 index 0000000000000000000000000000000000000000..8cc54316209214c955ab13cf99637111a50b6f57 --- /dev/null +++ b/labs/docker/nginx/nginx.conf @@ -0,0 +1,263 @@ +user www-data; +worker_processes auto; +pid /run/nginx.pid; + +events { + worker_connections 768; +} + +http { + ## + # Basic Settings + ## + + sendfile on; + tcp_nopush on; + tcp_nodelay on; + keepalive_timeout 65; + types_hash_max_size 2048; + + include /etc/nginx/mime.types; + default_type application/octet-stream; + + ## + # SSL Settings + ## + + ssl_protocols TLSv1 TLSv1.1 TLSv1.2; # Dropping SSLv3, ref: POODLE + ssl_prefer_server_ciphers on; + + ## + # Logging Settings + ## + + access_log /var/log/nginx/access.log; + error_log /var/log/nginx/error.log; + + ## + # Gzip Settings + ## + + gzip on; + gzip_disable "msie6"; + + ## + # Virtual Host Configs + ## + + server { + listen 80; + listen [::]:80; + server_name felipe-docker.mconf.com; + listen 443 ssl; + listen [::]:443 ssl; + ssl_certificate /etc/letsencrypt/live/felipe-docker.mconf.com/fullchain.pem; + ssl_certificate_key /etc/letsencrypt/live/felipe-docker.mconf.com/privkey.pem; + ssl_session_cache shared:SSL:10m; + ssl_session_timeout 10m; + # need TLSv1 for the Java calls for the API, otherwise it would be removed + ssl_protocols TLSv1 TLSv1.1 TLSv1.2; + ssl_ciphers "EECDH+AESGCM:EDH+AESGCM:AES256+EECDH:AES256+EDH"; + ssl_prefer_server_ciphers on; + ssl_dhparam /etc/nginx/ssl/dhp-2048.pem; + ssl_ecdh_curve secp384r1; + ssl_session_tickets off; + ssl_stapling on; + ssl_stapling_verify on; + add_header Strict-Transport-Security "max-age=31536000; includeSubDomains; preload"; + + access_log /var/log/nginx/bigbluebutton.access.log; + + # Handle RTMPT (RTMP Tunneling). Forwards requests + # to Red5 on port 5080 + location ~ (/open/|/close/|/idle/|/send/|/fcs/) { + proxy_pass http://127.0.0.1:5080; + proxy_redirect off; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + + client_max_body_size 10m; + client_body_buffer_size 128k; + + proxy_connect_timeout 90; + proxy_send_timeout 90; + proxy_read_timeout 90; + + proxy_buffering off; + keepalive_requests 1000000000; + } + + # Handle desktop sharing tunneling. Forwards + # requests to Red5 on port 5080. + location /deskshare { + proxy_pass http://127.0.0.1:5080; + proxy_redirect default; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + client_max_body_size 10m; + client_body_buffer_size 128k; + proxy_connect_timeout 90; + proxy_send_timeout 90; + proxy_read_timeout 90; + proxy_buffer_size 4k; + proxy_buffers 4 32k; + proxy_busy_buffers_size 64k; + proxy_temp_file_write_size 64k; + include fastcgi_params; + } + + # BigBlueButton landing page. + location / { + root /var/www/bigbluebutton-default; + index index.html index.htm; + expires 1m; + } + + # BigBlueButton.html is here so we can expire it every 1 minute to + # prevent caching. + location /client/BigBlueButton.html { + root /var/www/bigbluebutton; + index index.html index.htm; + expires 1m; + } + + # BigBlueButton Flash client. + location /client { + root /var/www/bigbluebutton; + index index.html index.htm; + } + + location /playback/presentation/playback.html { + return 301 /playback/presentation/0.81/playback.html?$query_string; + } + + location /playback/presentation { + root /var/bigbluebutton; + index index.html index.htm; + } + + location /presentation { + root /var/bigbluebutton/published; + index index.html index.htm; + } + + # Handle desktop sharing tunneling. Forwards + # requests to Red5 on port 5080. + location /screenshare { + proxy_pass http://127.0.0.1:5080; + proxy_redirect default; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + client_max_body_size 10m; + client_body_buffer_size 128k; + proxy_connect_timeout 90; + proxy_send_timeout 90; + proxy_read_timeout 90; + proxy_buffer_size 4k; + proxy_buffers 4 32k; + proxy_busy_buffers_size 64k; + proxy_temp_file_write_size 64k; + include fastcgi_params; + } + + location /ws { + proxy_pass https://45.55.44.165:7443; + proxy_http_version 1.1; + proxy_set_header Upgrade $http_upgrade; + proxy_set_header Connection "Upgrade"; + proxy_read_timeout 6h; + proxy_send_timeout 6h; + client_body_timeout 6h; + send_timeout 6h; + } + + # Pass to the webhooks app all requests made to the webhooks API. + location /bigbluebutton/api/hooks { + proxy_pass http://bbb-webhooks:3005; + proxy_redirect default; + proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; + proxy_set_header X-Real-IP $remote_addr; + proxy_set_header Host $http_host; + proxy_set_header X-NginX-Proxy true; + } + + # Handle request to bbb-web running within Tomcat. This is for + # the BBB-API and Presentation. + location /bigbluebutton { + proxy_pass http://bbb-web:8080; + proxy_redirect default; + 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"'; + + # Allow 30M uploaded presentation document. + client_max_body_size 30m; + client_body_buffer_size 128k; + + proxy_connect_timeout 90; + proxy_send_timeout 90; + proxy_read_timeout 90; + + proxy_buffer_size 4k; + proxy_buffers 4 32k; + proxy_busy_buffers_size 64k; + proxy_temp_file_write_size 64k; + + include fastcgi_params; + } + + location /bbb-webrtc-sfu { + proxy_pass http://bbb-webrtc-sfu:3008; + proxy_http_version 1.1; + proxy_set_header Upgrade $http_upgrade; + proxy_set_header Connection "Upgrade"; + proxy_read_timeout 6h; + proxy_send_timeout 6h; + client_body_timeout 6h; + send_timeout 6h; + } + + location /html5client { + proxy_pass http://bbb-html5:3000; + proxy_http_version 1.1; + proxy_set_header Upgrade $http_upgrade; + proxy_set_header Connection "Upgrade"; + } + + location /_timesync { + proxy_pass http://bbb-html5:3000; + } + + # Routes requests to Greenlight based on the '/b' prefix + location /b { + proxy_pass http://greenlight: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 /b/cable { + proxy_pass http://greenlight: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; + } + + # Redirect server error pages to the static page /50x.html + # + error_page 500 502 503 504 /50x.html; + location = /50x.html { + root /var/www/nginx-default; + } + + location = / { + return 301 /b; + } + } +} diff --git a/nginx.conf b/nginx.conf deleted file mode 100644 index c1af4c4f9ff32d2352b5105b41b87317098497ae..0000000000000000000000000000000000000000 --- a/nginx.conf +++ /dev/null @@ -1,259 +0,0 @@ -user www-data; -worker_processes auto; -pid /run/nginx.pid; - -events { - worker_connections 768; -} - -http { - ## - # Basic Settings - ## - - sendfile on; - tcp_nopush on; - tcp_nodelay on; - keepalive_timeout 65; - types_hash_max_size 2048; - - include /etc/nginx/mime.types; - default_type application/octet-stream; - - ## - # SSL Settings - ## - - ssl_protocols TLSv1 TLSv1.1 TLSv1.2; # Dropping SSLv3, ref: POODLE - ssl_prefer_server_ciphers on; - - ## - # Logging Settings - ## - - access_log /var/log/nginx/access.log; - error_log /var/log/nginx/error.log; - - ## - # Gzip Settings - ## - - gzip on; - gzip_disable "msie6"; - - ## - # Virtual Host Configs - ## - - server { - listen 80; - listen [::]:80; - server_name felipe-docker.mconf.com; - listen 443 ssl; - listen [::]:443 ssl; - ssl_certificate /etc/letsencrypt/live/felipe-docker.mconf.com/fullchain.pem; - ssl_certificate_key /etc/letsencrypt/live/felipe-docker.mconf.com/privkey.pem; - ssl_session_cache shared:SSL:10m; - ssl_session_timeout 10m; - # need TLSv1 for the Java calls for the API, otherwise it would be removed - ssl_protocols TLSv1 TLSv1.1 TLSv1.2; - ssl_ciphers "EECDH+AESGCM:EDH+AESGCM:AES256+EECDH:AES256+EDH"; - ssl_prefer_server_ciphers on; - ssl_dhparam /etc/nginx/ssl/dhp-2048.pem; - ssl_ecdh_curve secp384r1; # Requires nginx >= 1.1.0 - ssl_session_tickets off; # Requires nginx >= 1.5.9 - ssl_stapling on; # Requires nginx >= 1.3.7 - ssl_stapling_verify on; # Requires nginx => 1.3.7 - add_header Strict-Transport-Security "max-age=31536000; includeSubDomains; preload"; - - access_log /var/log/nginx/bigbluebutton.access.log; - - # Handle RTMPT (RTMP Tunneling). Forwards requests - # to Red5 on port 5080 - location ~ (/open/|/close/|/idle/|/send/|/fcs/) { - proxy_pass http://127.0.0.1:5080; - proxy_redirect off; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - - client_max_body_size 10m; - client_body_buffer_size 128k; - - proxy_connect_timeout 90; - proxy_send_timeout 90; - proxy_read_timeout 90; - - proxy_buffering off; - keepalive_requests 1000000000; - } - - # Handle desktop sharing tunneling. Forwards - # requests to Red5 on port 5080. - location /deskshare { - proxy_pass http://127.0.0.1:5080; - proxy_redirect default; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - client_max_body_size 10m; - client_body_buffer_size 128k; - proxy_connect_timeout 90; - proxy_send_timeout 90; - proxy_read_timeout 90; - proxy_buffer_size 4k; - proxy_buffers 4 32k; - proxy_busy_buffers_size 64k; - proxy_temp_file_write_size 64k; - include fastcgi_params; - } - - # BigBlueButton landing page. - location / { - root /var/www/bigbluebutton-default; - index index.html index.htm; - expires 1m; - } - - # BigBlueButton.html is here so we can expire it every 1 minute to - # prevent caching. - location /client/BigBlueButton.html { - root /var/www/bigbluebutton; - index index.html index.htm; - expires 1m; - } - - # BigBlueButton Flash client. - location /client { - root /var/www/bigbluebutton; - index index.html index.htm; - } - - # Forward request to /demo to tomcat. This is for - # the BigBlueButton api demos. - location /demo { - proxy_pass http://127.0.0.1:8080; - proxy_redirect default; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - - # Allow 30M uploaded presentation document. - client_max_body_size 30m; - client_body_buffer_size 128k; - - proxy_connect_timeout 90; - proxy_send_timeout 90; - proxy_read_timeout 90; - - proxy_buffer_size 4k; - proxy_buffers 4 32k; - proxy_busy_buffers_size 64k; - proxy_temp_file_write_size 64k; - - include fastcgi_params; - } - - location /playback/presentation/playback.html { - return 301 /playback/presentation/0.81/playback.html?$query_string; - } - - location /playback/presentation { - root /var/bigbluebutton; - index index.html index.htm; - } - - location /presentation { - root /var/bigbluebutton/published; - index index.html index.htm; - } - - # Handle desktop sharing tunneling. Forwards - # requests to Red5 on port 5080. - location /screenshare { - proxy_pass http://127.0.0.1:5080; - proxy_redirect default; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - client_max_body_size 10m; - client_body_buffer_size 128k; - proxy_connect_timeout 90; - proxy_send_timeout 90; - proxy_read_timeout 90; - proxy_buffer_size 4k; - proxy_buffers 4 32k; - proxy_busy_buffers_size 64k; - proxy_temp_file_write_size 64k; - include fastcgi_params; - } - - location /ws { - proxy_pass https://45.55.44.165:7443; - proxy_http_version 1.1; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection "Upgrade"; - proxy_read_timeout 6h; - proxy_send_timeout 6h; - client_body_timeout 6h; - send_timeout 6h; - } - - # Pass to the webhooks app all requests made to the webhooks API. - location /bigbluebutton/api/hooks { - proxy_pass http://bbb-webhooks:3005; - proxy_redirect default; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header Host $http_host; - proxy_set_header X-NginX-Proxy true; - } - - # Handle request to bbb-web running within Tomcat. This is for - # the BBB-API and Presentation. - location /bigbluebutton { - proxy_pass http://bbb-web:8080; - proxy_redirect default; - 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"'; - - # Allow 30M uploaded presentation document. - client_max_body_size 30m; - client_body_buffer_size 128k; - - proxy_connect_timeout 90; - proxy_send_timeout 90; - proxy_read_timeout 90; - - proxy_buffer_size 4k; - proxy_buffers 4 32k; - proxy_busy_buffers_size 64k; - proxy_temp_file_write_size 64k; - - include fastcgi_params; - } - - location /bbb-webrtc-sfu { - proxy_pass http://bbb-webrtc-sfu:3008; - proxy_http_version 1.1; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection "Upgrade"; - proxy_read_timeout 6h; - proxy_send_timeout 6h; - client_body_timeout 6h; - send_timeout 6h; - } - - location /html5client { - proxy_pass http://bbb-html5:3000; - proxy_http_version 1.1; - proxy_set_header Upgrade $http_upgrade; - proxy_set_header Connection "Upgrade"; - } - - location /_timesync { - proxy_pass http://bbb-html5:3000; - } - - # Redirect server error pages to the static page /50x.html - # - error_page 500 502 503 504 /50x.html; - location = /50x.html { - root /var/www/nginx-default; - } - } -}