Skip to content
This repository was archived by the owner on Dec 14, 2021. It is now read-only.

Commit 55d35d2

Browse files
committed
scripts: 'compose' and some minor fixes
1 parent 7148ae7 commit 55d35d2

File tree

5 files changed

+32
-16
lines changed

5 files changed

+32
-16
lines changed

docker-compose.greenlight.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ version: '3.6'
22

33
services:
44
greenlight:
5-
container_name: greenlight-v2
5+
container_name: greenlight
66
image: bigbluebutton/greenlight:v2
77
env_file: .env
88
environment:

docker-compose.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ services:
1111
SHARED_SECRET: ${SHARED_SECRET}
1212
WELCOME_FOOTER: ${WELCOME_FOOTER}
1313
STUN_SERVER: stun:${STUN_IP}:${STUN_PORT}
14-
TURN_SERVER: ${TURN_SERVER}
15-
TURN_SECRET: ${TURN_SECRET}
14+
TURN_SERVER: ${TURN_SERVER:-}
15+
TURN_SECRET: ${TURN_SECRET:-}
1616
volumes:
1717
- bigbluebutton:/var/bigbluebutton
1818
networks:

scripts/compose

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
#!/bin/bash
2+
set -e
3+
4+
cd $(dirname $0)/..
5+
6+
# load .env
7+
if [ -f .env ]
8+
then
9+
# exclude WELCOME_FOOTER because it may contain invalid characters
10+
export $(cat .env | sed 's/#.*//g' | grep -v "WELCOME_FOOTER" | xargs)
11+
fi
12+
13+
# concatenate docker-compose file
14+
COMPOSE_FILES="-f docker-compose.yml"
15+
if [ "$ENABLE_HTTPS_PROXY" == true ]; then
16+
COMPOSE_FILES="$COMPOSE_FILES -f docker-compose.https.yml"
17+
fi
18+
if [ "$ENABLE_GREENLIGHT" == true ]; then
19+
COMPOSE_FILES="$COMPOSE_FILES -f docker-compose.greenlight.yml"
20+
fi
21+
22+
docker-compose $COMPOSE_FILES $@

scripts/print-versions

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ CORE_IMAGE=$(docker-compose images -q core)
55
FREESWITCH_IMAGE=$(docker-compose images -q freeswitch)
66
HTML5_IMAGE=$(docker-compose images -q html5)
77
KURENTO_IMAGE=$(docker-compose images -q kurento)
8+
ETHERPAD_IMAGE=$(docker-compose images -q etherpad)
89
MONGO_IMAGE=$(docker-compose images -q mongodb)
910
REDIS_IMAGE=$(docker-compose images -q redis)
1011

@@ -30,7 +31,7 @@ docker run --rm --entrypoint /bin/sh $CORE_IMAGE -c "dpkg -l 'bbb-*' | grep ii |
3031
echo ""
3132

3233
echo "etherpad"
33-
ETHERPAD_VERSION=$(docker-compose images etherpad | grep etherpad | awk '{print $3}')
34+
ETHERPAD_VERSION=$(docker run --rm --entrypoint cat $ETHERPAD_IMAGE /opt/etherpad-lite/src/package.json | grep version | awk -F'"' '{print $4}')
3435
echo " version: $ETHERPAD_VERSION"
3536
echo ""
3637

scripts/upgrade

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ if [ -z $RESTARTED ]
77
then
88

99
echo "# pull newest bigblugbutton-docker.git"
10-
#git pull
10+
git pull
1111

1212
# restart script, since it might have changed.
1313
RESTARTED=1 ./scripts/upgrade
@@ -20,13 +20,11 @@ else
2020

2121
echo ""
2222
echo "# pull newest images"
23-
docker-compose pull
24-
docker-compose -f docker-compose.greenlight.yml pull
25-
docker-compose -f docker-compose.https.yml pull
23+
./scripts/compose pull
2624

2725
echo ""
2826
echo "# rebuild images"
29-
docker-compose build --pull --no-cache
27+
./scripts/compose build --pull --no-cache
3028

3129

3230
COMMIT_HASH=$(git rev-parse --short HEAD)
@@ -37,12 +35,7 @@ else
3735
echo "images successfully rebuilt!"
3836
echo "we are on $COMMIT_HASH ($BRANCH_NAME)"
3937
echo ""
40-
echo "use following commands for restarting:"
41-
echo "BigBlueButton:"
42-
echo " $ docker-compose up -d"
43-
echo "HTTPS Proxy:"
44-
echo " $ docker-compose -f docker-compose.https.yml up -d"
45-
echo "Greenlight:"
46-
echo " $ docker-compose -f docker-compose.greenlight.yml up -d"
38+
echo "use following command for restarting:"
39+
echo " $ ./scripts/compose up -d"
4740
echo "-------------------------------------"
4841
fi

0 commit comments

Comments
 (0)