From 09c3229d9d5819732c87938ce55438ec22de1c15 Mon Sep 17 00:00:00 2001 From: Xinwei Xiong <3293172751@qq.com> Date: Thu, 4 Jan 2024 16:01:32 +0800 Subject: [PATCH] feat(main): fix openim docker start openim server internal port lock (#1673) * fix: fix the bug * fix: fix the imAdmin permission and searchNoficitaion resp * 2023 Annual Summary Reflections and Aspirations Signed-off-by: Xinwei Xiong (cubxxw) <3293172751nss@gmail.com> --------- Signed-off-by: Xinwei Xiong (cubxxw) <3293172751nss@gmail.com> Co-authored-by: luhaoling <2198702716@qq.com> --- pkg/authverify/token.go | 1 - scripts/docker-start-all.sh | 19 +++++++++++++++++++ 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/pkg/authverify/token.go b/pkg/authverify/token.go index e810dfecf..4c71224ee 100644 --- a/pkg/authverify/token.go +++ b/pkg/authverify/token.go @@ -76,7 +76,6 @@ func ParseRedisInterfaceToken(redisToken any) (*tokenverify.Claims, error) { func IsManagerUserID(opUserID string) bool { return utils.IsContain(opUserID, config.Config.Manager.UserID) || utils.IsContain(opUserID, config.Config.IMAdmin.UserID) - } func WsVerifyToken(token, userID string, platformID int) error { diff --git a/scripts/docker-start-all.sh b/scripts/docker-start-all.sh index 3c83b02bb..85954a677 100755 --- a/scripts/docker-start-all.sh +++ b/scripts/docker-start-all.sh @@ -21,6 +21,25 @@ set -o pipefail #fixme This scripts is the total startup scripts #fixme The full name of the shell scripts that needs to be started is placed in the need_to_start_server_shell array +# Fixed ports inside the docker startup container +export OPENIM_WS_PORT=10001 +export API_OPENIM_PORT=10002 +export API_PROM_PORT=20100 +export USER_PROM_PORT=20110 +export FRIEND_PROM_PORT=20120 +export MESSAGE_PROM_PORT=20130 +export MSG_GATEWAY_PROM_PORT=20140 +export GROUP_PROM_PORT=20150 +export AUTH_PROM_PORT=20160 +export PUSH_PROM_PORT=20170 +export CONVERSATION_PROM_PORT=20230 +export RTC_PROM_PORT=21300 +export THIRD_PROM_PORT=21301 +export MSG_TRANSFER_PROM_PORT=21400 +export MSG_TRANSFER_PROM_PORT=21401 +export MSG_TRANSFER_PROM_PORT=21402 +export MSG_TRANSFER_PROM_PORT=21403 + OPENIM_ROOT=$(dirname "${BASH_SOURCE[0]}")/.. source "${OPENIM_ROOT}/scripts/install/common.sh"