feat: switch client API branding to MeetingIM

This commit is contained in:
richjohnrambo
2026-08-31 01:22:53 +08:00
parent c6a243ee59
commit 9f647de4d0
48 changed files with 717 additions and 271 deletions
+12 -12
View File
@@ -1,7 +1,7 @@
#!/bin/bash
BINARY_PATH=$GOPATH/bin
TINODE_BINARY=$BINARY_PATH/server
MEETINGIM_BINARY=$BINARY_PATH/server
# Kills and removes any running containers.
cleanup() {
@@ -45,23 +45,23 @@ setup() {
echo -n "."
sleep 1
done
# Make sure there's no Tinode server binary in the current directory.
# Make sure there's no MeetingIM server binary in the current directory.
if [ -f "./server" ]; then
rm ./server
fi
}
# Compiles Tinode binaries.
# Compiles MeetingIM binaries.
build() {
go install -tags mysql -ldflags "-X main.buildstamp=`date -u '+%Y%m%dT%H:%M:%SZ'`" \
github.com/tinode/chat/tinode-db \
github.com/tinode/chat/server && \
ln -s $TINODE_BINARY
ln -s $MEETINGIM_BINARY
}
# Initializes Tinode database.
# Initializes MeetingIM database.
init-db() {
$GOPATH/bin/tinode-db -config=./tinode.conf -data=../tinode-db/data.json
$GOPATH/bin/tinode-db -config=./meetingim.conf -data=../tinode-db/data.json
}
wait-for() {
@@ -71,7 +71,7 @@ wait-for() {
done
}
# Brings up a three-node Tinode cluster.
# Brings up a three-node MeetingIM cluster.
run-server() {
./run-cluster.sh -s "" start && wait-for 16060
}
@@ -80,7 +80,7 @@ send-requests() {
local expect=12
local port=$1
local id=$2
local outfile=$(mktemp /tmp/tinode-${id}.txt)
local outfile=$(mktemp /tmp/meetingim-${id}.txt)
pushd .
cd ../tn-cli
python3 tn-cli.py --host=localhost:${port} --no-login < sample-script.txt > $outfile || fail "Test script failed (instance port ${port})"
@@ -103,14 +103,14 @@ trap 'cleanup ; fail "For Unexpected Reasons"'\
run_id=`date +%s`
echo "+----------------------------------------------------+"
echo "| Tinode sanity test. |"
echo "| MeetingIM sanity test. |"
echo "+----------------------------------------------------+"
echo "Timestamp = ${run_id}"
setup || fail "Test setup failed."
build || fail "Could not build Tinode binaries"
init-db || fail "Could not initialize Tinode database"
run-server || fail "Could not start tinode"
build || fail "Could not build MeetingIM binaries"
init-db || fail "Could not initialize MeetingIM database"
run-server || fail "Could not start meetingim"
# Test requests.
send-requests 16060 $run_id