Skip to content

Commit

Permalink
use local sources instead of pulling inside container
Browse files Browse the repository at this point in the history
  • Loading branch information
alangecker committed Dec 7, 2023
1 parent d6341e3 commit 03dcee6
Show file tree
Hide file tree
Showing 26 changed files with 137 additions and 227 deletions.
34 changes: 20 additions & 14 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,18 +1,24 @@
[submodule "bbb-webrtc-sfu"]
path = mod/webrtc-sfu/bbb-webrtc-sfu
url = https://github.com/bigbluebutton/bbb-webrtc-sfu.git
[submodule "mod/etherpad/bbb-etherpad-skin"]
path = mod/etherpad/bbb-etherpad-skin
[submodule "repos/bbb-etherpad-skin"]
path = repos/bbb-etherpad-skin
url = https://github.com/alangecker/bbb-etherpad-skin
[submodule "mod/etherpad/bbb-etherpad-plugin"]
path = mod/etherpad/bbb-etherpad-plugin
[submodule "repos/bbb-etherpad-plugin"]
path = repos/bbb-etherpad-plugin
url = https://github.com/alangecker/bbb-etherpad-plugin
[submodule "mod/bbb-pads/bbb-pads"]
path = mod/bbb-pads/bbb-pads
url = https://github.com/bigbluebutton/bbb-pads
[submodule "mod/webhooks/bbb-webhooks"]
path = mod/webhooks/bbb-webhooks
[submodule "repos/bbb-webhooks"]
path = repos/bbb-webhooks
url = https://github.com/bigbluebutton/bbb-webhooks
[submodule "mod/nginx/bbb-playback"]
path = mod/nginx/bbb-playback
[submodule "repos/bbb-playback"]
path = repos/bbb-playback
url = https://github.com/bigbluebutton/bbb-playback
[submodule "repos/freeswitch"]
path = repos/freeswitch
url = https://github.com/signalwire/freeswitch.git
[submodule "repos/bigbluebutton"]
path = repos/bigbluebutton
url = https://github.com/bigbluebutton/bigbluebutton.git
[submodule "repos/bbb-webrtc-sfu"]
path = repos/bbb-webrtc-sfu
url = https://github.com/bigbluebutton/bbb-webrtc-sfu.git
[submodule "repos/bbb-pads"]
path = repos/bbb-pads
url = https://github.com/bigbluebutton/bbb-pads.git
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Version: 2.7.3 | [Changelog](CHANGELOG.md) | [Issues](https://github.com/bigblue
4. Ensure docker compose works and that you use a version ≥ 1.28 : `$ docker compose --version`
2. Clone this repository
```sh
$ git clone --recurse-submodules https://github.com/bigbluebutton/docker.git bbb-docker
$ git clone https://github.com/bigbluebutton/docker.git bbb-docker
$ cd bbb-docker

# use the more stable main branch (sometimes older)
Expand Down
93 changes: 60 additions & 33 deletions docker-compose.tmpl.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,12 @@ version: '3.6'
x-html5-backend: &html5backend
build:
context: mod/html5
additional_contexts:
- source=./repos/bigbluebutton/bigbluebutton-html5
args:
BBB_BUILD_TAG: {{ .Env.BBB_BUILD_TAG }}
TAG_HTML5: {{ .Env.TAG_HTML5 }}
image: alangecker/bbb-docker-html5:{{ .Env.TAG_HTML5 }}
BBB_BUILD_TAG: bbb27-2023-06-13-java17
TAG_BBB: {{ .Env.TAG_BBB }}
image: alangecker/bbb-docker-html5:{{ .Env.TAG_BBB }}
restart: unless-stopped
depends_on:
- redis
Expand Down Expand Up @@ -44,11 +46,13 @@ services:
bbb-web:
build:
context: mod/bbb-web
additional_contexts:
- src-web=./repos/bigbluebutton/bigbluebutton-web
- src-common-message=./repos/bigbluebutton/bbb-common-message
- src-common-web=./repos/bigbluebutton/bbb-common-web
args:
BBB_BUILD_TAG: {{ .Env.BBB_BUILD_TAG }}
TAG_COMMON_MESSAGE: {{ .Env.TAG_COMMON_MESSAGE }}
TAG_BBB_WEB: {{ .Env.TAG_BBB_WEB }}
image: alangecker/bbb-docker-web:{{ .Env.TAG_BBB_WEB }}
BBB_BUILD_TAG: bbb27-2023-06-13-java17
image: alangecker/bbb-docker-web:{{ .Env.TAG_BBB }}
restart: unless-stopped
depends_on:
- redis
Expand Down Expand Up @@ -106,12 +110,13 @@ services:
container_name: bbb-freeswitch
build:
context: mod/freeswitch
additional_contexts:
- freeswitch=./repos/freeswitch/
- build-files=./repos/bigbluebutton/build/packages-template/bbb-freeswitch-core/
- fs-config=./repos/bigbluebutton/bbb-voice-conference/config/freeswitch/conf/
args:
BBB_BUILD_TAG: {{ .Env.BBB_BUILD_TAG }}
TAG_FS_BUILD_FILES: {{ .Env.TAG_FS_BUILD_FILES }}
TAG_FS_CONFIG: {{ .Env.TAG_FS_CONFIG }}
TAG_FREESWITCH: {{ .Env.TAG_FREESWITCH }}
image: alangecker/bbb-docker-freeswitch:{{ .Env.TAG_FS_CONFIG }}
BBB_BUILD_TAG: bbb27-2023-06-13-java17
image: alangecker/bbb-docker-freeswitch:{{ .Env.TAG_FREESWITCH }}-{{ .Env.TAG_BBB }}
restart: unless-stopped
cap_add:
- IPC_LOCK
Expand Down Expand Up @@ -145,10 +150,12 @@ services:
nginx:
build:
context: mod/nginx
additional_contexts:
- src-learning-dashboard=./repos/bigbluebutton/bbb-learning-dashboard
- src-playback=./repos/bbb-playback
args:
BBB_BUILD_TAG: {{ .Env.BBB_BUILD_TAG }}
TAG_LEARNING_DASHBOARD: {{ .Env.TAG_LEARNING_DASHBOARD }}
image: alangecker/bbb-docker-nginx:1.23-{{ .Env.TAG_PLAYBACK }}-{{ .Env.TAG_LEARNING_DASHBOARD }}
BBB_BUILD_TAG: bbb27-2023-06-13-java17
image: alangecker/bbb-docker-nginx:1.23-{{ .Env.TAG_PLAYBACK }}-{{ .Env.TAG_BBB }}
restart: unless-stopped
depends_on:
- etherpad
Expand All @@ -168,8 +175,14 @@ services:
- "greenlight:10.7.7.21"

etherpad:
build: mod/etherpad
image: alangecker/bbb-docker-etherpad:1.9.1
build:
context: mod/etherpad
additional_contexts:
- plugin=./repos/bbb-etherpad-plugin
- skin=./repos/bbb-etherpad-skin
args:
TAG_ETHERPAD: "1.9.1"
image: alangecker/bbb-docker-etherpad:1.9.1-s{{ .Env.COMMIT_ETHERPAD_SKIN }}-p{{ .Env.COMMIT_ETHERPAD_PLUGIN }}
restart: unless-stopped
depends_on:
- redis
Expand All @@ -180,7 +193,10 @@ services:
ipv4_address: 10.7.7.4

bbb-pads:
build: mod/bbb-pads
build:
context: mod/bbb-pads
additional_contexts:
- src=./repos/bbb-pads
image: alangecker/bbb-docker-pads:{{ .Env.TAG_PADS }}
restart: unless-stopped
depends_on:
Expand Down Expand Up @@ -232,8 +248,10 @@ services:
webrtc-sfu:
build:
context: mod/webrtc-sfu
additional_contexts:
- source=./repos/bbb-webrtc-sfu
args:
BBB_BUILD_TAG: {{ .Env.BBB_BUILD_TAG }}
BBB_BUILD_TAG: bbb27-2023-06-13-java17
image: alangecker/bbb-docker-webrtc-sfu:{{ .Env.TAG_WEBRTC_SFU }}
restart: unless-stopped
depends_on:
Expand Down Expand Up @@ -266,11 +284,13 @@ services:
fsesl-akka:
build:
context: mod/fsesl-akka
additional_contexts:
- src-common-message=./repos/bigbluebutton/bbb-common-message
- src-fsesl-client=./repos/bigbluebutton/bbb-fsesl-client
- src-fsesl-akka=./repos/bigbluebutton/akka-bbb-fsesl
args:
BBB_BUILD_TAG: {{ .Env.BBB_BUILD_TAG }}
TAG_COMMON_MESSAGE: {{ .Env.TAG_COMMON_MESSAGE }}
TAG_FSESL_AKKA: {{ .Env.TAG_FSESL_AKKA }}
image: alangecker/bbb-docker-fsesl-akka:{{ .Env.TAG_FSESL_AKKA }}
BBB_BUILD_TAG: bbb27-2023-06-13-java17
image: alangecker/bbb-docker-fsesl-akka:{{ .Env.TAG_BBB }}
restart: unless-stopped
depends_on:
- redis
Expand All @@ -284,11 +304,12 @@ services:
apps-akka:
build:
context: mod/apps-akka
additional_contexts:
- src-common-message=./repos/bigbluebutton/bbb-common-message
- src-apps-akka=./repos/bigbluebutton/akka-bbb-apps
args:
BBB_BUILD_TAG: {{ .Env.BBB_BUILD_TAG }}
TAG_COMMON_MESSAGE: {{ .Env.TAG_COMMON_MESSAGE }}
TAG_APPS_AKKA: {{ .Env.TAG_APPS_AKKA }}
image: alangecker/bbb-docker-apps-akka:{{ .Env.TAG_APPS_AKKA }}
BBB_BUILD_TAG: bbb27-2023-06-13-java17
image: alangecker/bbb-docker-apps-akka:{{ .Env.TAG_BBB }}
restart: unless-stopped
depends_on:
- redis
Expand Down Expand Up @@ -342,11 +363,14 @@ services:
recordings:
build:
context: mod/recordings
additional_contexts:
- record-core=./repos/bigbluebutton/record-and-playback/core
- presentation=./repos/bigbluebutton/record-and-playback/presentation
- bbb-conf=./repos/bigbluebutton/bigbluebutton-config
args:
BBB_BUILD_TAG: {{ .Env.BBB_BUILD_TAG }}
TAG_RECORDINGS: {{ .Env.TAG_RECORDINGS }}
TAG_BBB_PRESENTATION_VIDEO: {{ .Env.TAG_BBB_PRESENTATION_VIDEO }}
image: alangecker/bbb-docker-recordings:{{ .Env.TAG_RECORDINGS }}
BBB_BUILD_TAG: bbb27-2023-06-13-java17
TAG_BBB_PRESENTATION_VIDEO: "4.0.3"
image: alangecker/bbb-docker-recordings:{{ .Env.TAG_BBB }}
restart: unless-stopped
depends_on:
- redis
Expand All @@ -370,7 +394,10 @@ services:
{{ if isTrue .Env.ENABLE_WEBHOOKS }}
# webhooks
webhooks:
build: mod/webhooks
build:
context: mod/webhooks
additional_contexts:
- src=./repos/bbb-webhooks
image: alangecker/bbb-docker-webhooks:{{ .Env.TAG_WEBHOOKS }}
restart: unless-stopped
environment:
Expand Down Expand Up @@ -439,7 +466,7 @@ services:
{{ if isTrue .Env.ENABLE_GREENLIGHT }}
# greenlight
greenlight:
image: bigbluebutton/greenlight:{{ .Env.TAG_GREENLIGHT }}
image: bigbluebutton/greenlight:v3.0.6.1
restart: unless-stopped
env_file: .env
depends_on:
Expand Down
8 changes: 2 additions & 6 deletions docs/development.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,12 +70,8 @@ This always consists out of following steps
1. **Get an understanding about changes that happened and find out what changes to bbb-docker that require.** \
* main source for that are the release notes in https://github.com/bigbluebutton/bigbluebutton/releases
2. **Apply these changes to this project.**
* Often you only need to update the TAGS in `tags.env`
* make sure only to switch to a newer tag if there were changes made avoid creating new (partialy big) images unnecessarily
* Also update submodules to the new state.
* List of all submodules `git submodule`
* for the main submodules you can use `./scripts/checkout-submodules` to checkout the tags specified in `tags.env`

* Often you only need to checkout the git submodules to the specific release tag
* List of all submodules: `git submodule`
3. Test everything (with firefox **and** chromium/chrome)
* Audio
* Video
Expand Down
12 changes: 4 additions & 8 deletions mod/apps-akka/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,20 +1,16 @@
ARG BBB_BUILD_TAG
FROM bigbluebutton/bbb-build:$BBB_BUILD_TAG AS builder

ARG TAG_COMMON_MESSAGE
COPY --from=src-common-message / /bbb-common-message

# download bbb-common-message
RUN svn checkout https://github.com/bigbluebutton/bigbluebutton/tags/$TAG_COMMON_MESSAGE/bbb-common-message /bbb-common-message \
&& cd /bbb-common-message \
&& ./deploy.sh \
&& rm -rf /bbb-common-message
# build bbb-common-message
RUN cd /bbb-common-message && ./deploy.sh

# ===================================================

ARG TAG_APPS_AKKA

RUN svn checkout https://github.com/bigbluebutton/bigbluebutton/tags/$TAG_APPS_AKKA/akka-bbb-apps /source \
&& rm -rf /source/.svn
COPY --from=src-apps-akka / /source

# compile and unzip bin
RUN cd /source \
Expand Down
2 changes: 1 addition & 1 deletion mod/bbb-pads/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
FROM node:18-bullseye-slim AS builder

COPY ./bbb-pads /bbb-pads
COPY --from=src / /bbb-pads
RUN cd /bbb-pads && rm -r .git && npm install --production


Expand Down
24 changes: 7 additions & 17 deletions mod/bbb-web/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,29 +1,19 @@
ARG BBB_BUILD_TAG
FROM bigbluebutton/bbb-build:$BBB_BUILD_TAG AS builder

ARG TAG_COMMON_MESSAGE
COPY --from=src-common-message / /bbb-common-message

# download bbb-common-message
RUN svn checkout https://github.com/bigbluebutton/bigbluebutton/tags/$TAG_COMMON_MESSAGE/bbb-common-message /bbb-common-message \
&& cd /bbb-common-message \
&& ./deploy.sh \
&& rm -rf /bbb-common-message
# build bbb-common-message
RUN cd /bbb-common-message && ./deploy.sh

# ===================================================

ARG TAG_BBB_WEB

# download bbb-common-web
RUN svn checkout https://github.com/bigbluebutton/bigbluebutton/tags/$TAG_BBB_WEB/bbb-common-web /bbb-common-web \
&& rm -rf /bbb-common-message/.svn
COPY --from=src-common-web / /bbb-common-web
# build bbb-common-web
RUN cd /bbb-common-web && ./deploy.sh

# compile bbb-common-web
RUN cd /bbb-common-web \
&& ./deploy.sh

# download bbb-web
RUN svn checkout https://github.com/bigbluebutton/bigbluebutton/tags/$TAG_BBB_WEB/bigbluebutton-web /bbb-web \
&& rm -rf /bbb-web/.svn
COPY --from=src-web / /bbb-web

# compile bbb-web
RUN cd /bbb-web && grails assemble
Expand Down
7 changes: 4 additions & 3 deletions mod/etherpad/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
FROM etherpad/etherpad:1.9.4
ARG TAG_ETHERPAD
FROM etherpad/etherpad:$TAG_ETHERPAD

USER root

Expand All @@ -16,10 +17,10 @@ RUN npm install \
&& rm package-lock.json package.json

# add skin from git submodule
COPY --chown=etherpad:0 ./bbb-etherpad-skin /opt/etherpad-lite/src/static/skins/bigbluebutton
COPY --chown=etherpad:0 --from=skin / /opt/etherpad-lite/src/static/skins/bigbluebutton

# add plugin from git submodule
COPY --chown=etherpad:0 ./bbb-etherpad-plugin /opt/etherpad-lite/node_modules/ep_bigbluebutton_patches
COPY --chown=etherpad:0 --from=plugin / /opt/etherpad-lite/node_modules/ep_bigbluebutton_patches

COPY settings.json /opt/etherpad-lite/settings.json
COPY etherpad-export.sh /etherpad-export.sh
Expand Down
25 changes: 4 additions & 21 deletions mod/freeswitch/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,13 +1,7 @@
ARG BBB_BUILD_TAG
FROM bigbluebutton/bbb-build:$BBB_BUILD_TAG AS builder

ARG TAG_FREESWITCH
RUN mkdir -p /build/freeswitch && \
cd /build/freeswitch && \
git init && \
git remote add origin https://github.com/signalwire/freeswitch.git && \
git fetch --depth 1 origin $TAG_FREESWITCH && \
git checkout FETCH_HEAD
COPY --from=freeswitch / /build/freeswitch

# install most recent git version for proper sparse-checkout support
# https://stackoverflow.com/questions/72223738/failed-to-initialize-sparse-checkout
Expand All @@ -17,12 +11,7 @@ RUN echo 'deb https://ppa.launchpadcontent.net/git-core/ppa/ubuntu focal main' >
apt-get install -y git

# get build files for bbb-freeswitch (build/packages-template/bbb-freeswitch-core/)
ARG TAG_FS_BUILD_FILES
RUN git clone -b $TAG_FS_BUILD_FILES --depth 1 --filter=blob:none --sparse https://github.com/bigbluebutton/bigbluebutton.git /bbb && \
cd /bbb && \
git sparse-checkout set build/packages-template/bbb-freeswitch-core/ && \
cp build/packages-template/bbb-freeswitch-core/* /build/ && \
rm -rf /bbb
COPY --from=build-files / /build/

# mock files expected by build.sh
RUN mkdir -p /build/bbb-voice-conference/config/freeswitch/conf/ && \
Expand All @@ -33,7 +22,7 @@ RUN mkdir -p /build/bbb-voice-conference/config/freeswitch/conf/ && \
&& \
echo "" > /usr/local/bin/fpm


# build freeswitch
RUN cd /build && ./build.sh


Expand All @@ -48,13 +37,7 @@ RUN mkdir -p /build/staging/opt/freeswitch/share/freeswitch && \

# add bigblugbutton config
ARG TAG_FS_CONFIG
RUN git clone -b $TAG_FS_CONFIG --depth 1 --filter=blob:none --sparse https://github.com/bigbluebutton/bigbluebutton.git /bbb && \
cd /bbb && \
git sparse-checkout set bbb-voice-conference/config/freeswitch/conf/ && \
cp -r /bbb/bbb-voice-conference/config/freeswitch/conf/* /build/staging/opt/freeswitch/etc/freeswitch/



COPY --from=fs-config / /build/staging/opt/freeswitch/etc/freeswitch/

# ===============================================

Expand Down
Loading

0 comments on commit 03dcee6

Please sign in to comment.