mirror of
https://github.com/openimsdk/open-im-server.git
synced 2025-04-24 10:22:36 +08:00
modify dictory
This commit is contained in:
parent
df6eb2e6f1
commit
15ff930661
@ -7,7 +7,7 @@ BIN_DIR=../../bin/
|
|||||||
all: gotool build
|
all: gotool build
|
||||||
|
|
||||||
build:
|
build:
|
||||||
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s"
|
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s" -o ${BINARY_NAME}
|
||||||
|
|
||||||
run:
|
run:
|
||||||
@go run ./
|
@go run ./
|
||||||
|
@ -7,7 +7,7 @@ BIN_DIR=../../bin/
|
|||||||
all: gotool build
|
all: gotool build
|
||||||
|
|
||||||
build:
|
build:
|
||||||
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s"
|
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s" -o ${BINARY_NAME}
|
||||||
|
|
||||||
run:
|
run:
|
||||||
@go run ./
|
@go run ./
|
||||||
|
@ -6,7 +6,7 @@ BIN_DIR=../../bin/
|
|||||||
all: gotool build
|
all: gotool build
|
||||||
|
|
||||||
build:
|
build:
|
||||||
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s"
|
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s" -o ${BINARY_NAME}
|
||||||
|
|
||||||
run:
|
run:
|
||||||
@go run ./
|
@go run ./
|
||||||
|
@ -6,7 +6,7 @@ BIN_DIR=../../bin/
|
|||||||
all: gotool build
|
all: gotool build
|
||||||
|
|
||||||
build:
|
build:
|
||||||
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s"
|
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s" -o ${BINARY_NAME}
|
||||||
|
|
||||||
run:
|
run:
|
||||||
@go run ./
|
@go run ./
|
||||||
|
@ -7,7 +7,7 @@ BIN_DIR=../../bin/
|
|||||||
all: gotool build
|
all: gotool build
|
||||||
|
|
||||||
build:
|
build:
|
||||||
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s"
|
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s" -o ${BINARY_NAME}
|
||||||
|
|
||||||
run:
|
run:
|
||||||
@go run ./
|
@go run ./
|
||||||
|
@ -6,7 +6,7 @@ BIN_DIR=../../bin/
|
|||||||
all: gotool build
|
all: gotool build
|
||||||
|
|
||||||
build:
|
build:
|
||||||
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s"
|
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s" -o ${BINARY_NAME}
|
||||||
|
|
||||||
run:
|
run:
|
||||||
@go run ./
|
@go run ./
|
||||||
|
@ -6,7 +6,7 @@ BIN_DIR=../../../bin/
|
|||||||
all: gotool build
|
all: gotool build
|
||||||
|
|
||||||
build:
|
build:
|
||||||
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s"
|
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s" -o ${BINARY_NAME}
|
||||||
|
|
||||||
run:
|
run:
|
||||||
@go run ./
|
@go run ./
|
||||||
|
@ -6,7 +6,7 @@ BIN_DIR=../../../bin/
|
|||||||
all: gotool build
|
all: gotool build
|
||||||
|
|
||||||
build:
|
build:
|
||||||
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s"
|
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s" -o ${BINARY_NAME}
|
||||||
|
|
||||||
run:
|
run:
|
||||||
@go run ./
|
@go run ./
|
||||||
|
@ -6,7 +6,7 @@ BIN_DIR=../../../bin/
|
|||||||
all: gotool build
|
all: gotool build
|
||||||
|
|
||||||
build:
|
build:
|
||||||
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s"
|
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s" -o ${BINARY_NAME}
|
||||||
|
|
||||||
run:
|
run:
|
||||||
@go run ./
|
@go run ./
|
||||||
|
@ -6,7 +6,7 @@ BIN_DIR=../../../bin/
|
|||||||
all: gotool build
|
all: gotool build
|
||||||
|
|
||||||
build:
|
build:
|
||||||
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s"
|
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s" -o ${BINARY_NAME}
|
||||||
|
|
||||||
run:
|
run:
|
||||||
@go run ./
|
@go run ./
|
||||||
|
@ -6,7 +6,7 @@ BIN_DIR=../../../bin/
|
|||||||
all: gotool build
|
all: gotool build
|
||||||
|
|
||||||
build:
|
build:
|
||||||
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s"
|
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s" -o ${BINARY_NAME}
|
||||||
|
|
||||||
run:
|
run:
|
||||||
@go run ./
|
@go run ./
|
||||||
|
25
cmd/rpc/third/Makefile
Normal file
25
cmd/rpc/third/Makefile
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
.PHONY: all build run gotool install clean help
|
||||||
|
|
||||||
|
BINARY_NAME=open_im_third
|
||||||
|
BIN_DIR=../../../bin/
|
||||||
|
|
||||||
|
all: gotool build
|
||||||
|
|
||||||
|
build:
|
||||||
|
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s" -o ${BINARY_NAME}
|
||||||
|
|
||||||
|
run:
|
||||||
|
@go run ./
|
||||||
|
|
||||||
|
gotool:
|
||||||
|
go fmt ./
|
||||||
|
go vet ./
|
||||||
|
|
||||||
|
install:
|
||||||
|
make build
|
||||||
|
mv ${BINARY_NAME} ${BIN_DIR}
|
||||||
|
|
||||||
|
clean:
|
||||||
|
@if [ -f ${BINARY_NAME} ] ; then rm ${BINARY_NAME} ; fi
|
||||||
|
|
||||||
|
|
@ -10,7 +10,7 @@ func main() {
|
|||||||
if err := config.InitConfig(); err != nil {
|
if err := config.InitConfig(); err != nil {
|
||||||
panic(err.Error())
|
panic(err.Error())
|
||||||
}
|
}
|
||||||
if err := startrpc.Start(config.Config.RpcPort.OpenImUserPort[0], config.Config.RpcRegisterName.OpenImUserName, config.Config.Prometheus.UserPrometheusPort[0], third.Start); err != nil {
|
if err := startrpc.Start(config.Config.RpcPort.OpenImThirdPort[0], config.Config.RpcRegisterName.OpenImThirdName, config.Config.Prometheus.ThirdPrometheusPort[0], third.Start); err != nil {
|
||||||
panic(err.Error())
|
panic(err.Error())
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -6,7 +6,7 @@ BIN_DIR=../../../bin/
|
|||||||
all: gotool build
|
all: gotool build
|
||||||
|
|
||||||
build:
|
build:
|
||||||
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s"
|
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-w -s" -o ${BINARY_NAME}
|
||||||
|
|
||||||
run:
|
run:
|
||||||
@go run ./
|
@go run ./
|
||||||
|
@ -80,16 +80,6 @@ rpcRegisterIP:
|
|||||||
#默认即可
|
#默认即可
|
||||||
listenIP: 0.0.0.0
|
listenIP: 0.0.0.0
|
||||||
|
|
||||||
# endpoints 内部组件间访问的端点host名称,访问时,可以内部直接访问 host:port 来访问
|
|
||||||
endpoints:
|
|
||||||
api: openim_api
|
|
||||||
push: openim_push
|
|
||||||
msg_gateway: openim_msg_gateway
|
|
||||||
rpc_auth: openim_rpc_auth
|
|
||||||
rpc_friend: openim_rpc_friend
|
|
||||||
rpc_group: openim_rpc_group
|
|
||||||
rpc_msg: openim_rpc_msg
|
|
||||||
rpc_user: openim_rpc_user
|
|
||||||
|
|
||||||
api:
|
api:
|
||||||
openImApiPort: [ 10002 ] #api服务端口,默认即可,需要开放此端口或做nginx转发
|
openImApiPort: [ 10002 ] #api服务端口,默认即可,需要开放此端口或做nginx转发
|
||||||
@ -149,9 +139,9 @@ rpcport: #rpc服务端口 默认即可
|
|||||||
openImGroupPort: [ 10150 ]
|
openImGroupPort: [ 10150 ]
|
||||||
openImAuthPort: [ 10160 ]
|
openImAuthPort: [ 10160 ]
|
||||||
openImPushPort: [ 10170 ]
|
openImPushPort: [ 10170 ]
|
||||||
openImConversationPort: [ 10230 ]
|
openImConversationPort: [ 10180 ]
|
||||||
openImRtcPort: [ 11300 ]
|
openImRtcPort: [ 10190 ]
|
||||||
|
openImThirdPort : [ 10200 ]
|
||||||
|
|
||||||
rpcregistername: #rpc注册服务名,默认即可
|
rpcregistername: #rpc注册服务名,默认即可
|
||||||
openImUserName: User
|
openImUserName: User
|
||||||
@ -163,6 +153,7 @@ rpcregistername: #rpc注册服务名,默认即可
|
|||||||
openImAuthName: Auth
|
openImAuthName: Auth
|
||||||
openImConversationName: Conversation
|
openImConversationName: Conversation
|
||||||
openImRtcName: Rtc
|
openImRtcName: Rtc
|
||||||
|
openImThirdName: Third
|
||||||
|
|
||||||
log:
|
log:
|
||||||
storageLocation: ../logs/
|
storageLocation: ../logs/
|
||||||
@ -326,5 +317,5 @@ prometheus:
|
|||||||
authPrometheusPort: [ 20160 ]
|
authPrometheusPort: [ 20160 ]
|
||||||
pushPrometheusPort: [ 20170 ]
|
pushPrometheusPort: [ 20170 ]
|
||||||
conversationPrometheusPort: [ 20230 ]
|
conversationPrometheusPort: [ 20230 ]
|
||||||
RtcPrometheusPort: [ 21300 ]
|
rtcPrometheusPort: [ 21300 ]
|
||||||
messageTransferPrometheusPort: [ 21400, 21401, 21402, 21403 ] # 端口数量和 script/path_info.cfg msg_transfer_service_num保持一致
|
messageTransferPrometheusPort: [ 21400, 21401, 21402, 21403 ] # 端口数量和 script/path_info.cfg msg_transfer_service_num保持一致
|
||||||
|
@ -152,6 +152,7 @@ type config struct {
|
|||||||
OpenImConversationPort []int `yaml:"openImConversationPort"`
|
OpenImConversationPort []int `yaml:"openImConversationPort"`
|
||||||
OpenImCachePort []int `yaml:"openImCachePort"`
|
OpenImCachePort []int `yaml:"openImCachePort"`
|
||||||
OpenImRtcPort []int `yaml:"openImRtcPort"`
|
OpenImRtcPort []int `yaml:"openImRtcPort"`
|
||||||
|
OpenImThirdPort []int `yaml:"openImThirdPort"`
|
||||||
}
|
}
|
||||||
RpcRegisterName struct {
|
RpcRegisterName struct {
|
||||||
OpenImUserName string `yaml:"openImUserName"`
|
OpenImUserName string `yaml:"openImUserName"`
|
||||||
@ -301,8 +302,9 @@ type config struct {
|
|||||||
AuthPrometheusPort []int `yaml:"authPrometheusPort"`
|
AuthPrometheusPort []int `yaml:"authPrometheusPort"`
|
||||||
PushPrometheusPort []int `yaml:"pushPrometheusPort"`
|
PushPrometheusPort []int `yaml:"pushPrometheusPort"`
|
||||||
ConversationPrometheusPort []int `yaml:"conversationPrometheusPort"`
|
ConversationPrometheusPort []int `yaml:"conversationPrometheusPort"`
|
||||||
RtcPrometheusPort []int `yaml:"RtcPrometheusPort"`
|
RtcPrometheusPort []int `yaml:"rtcPrometheusPort"`
|
||||||
MessageTransferPrometheusPort []int `yaml:"messageTransferPrometheusPort"`
|
MessageTransferPrometheusPort []int `yaml:"messageTransferPrometheusPort"`
|
||||||
|
ThirdPrometheusPort []int `yaml:"thirdPrometheusPort"`
|
||||||
} `yaml:"prometheus"`
|
} `yaml:"prometheus"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -46,6 +46,7 @@ service_source_root=(
|
|||||||
../cmd/rpc/group/
|
../cmd/rpc/group/
|
||||||
../cmd/rpc/auth/
|
../cmd/rpc/auth/
|
||||||
../cmd/rpc/conversation/
|
../cmd/rpc/conversation/
|
||||||
|
../cmd/rpc/third/
|
||||||
../cmd/crontask
|
../cmd/crontask
|
||||||
../cmd/cmdutils
|
../cmd/cmdutils
|
||||||
# ${msg_gateway_source_root}
|
# ${msg_gateway_source_root}
|
||||||
@ -64,6 +65,7 @@ service_names=(
|
|||||||
open_im_group
|
open_im_group
|
||||||
open_im_auth
|
open_im_auth
|
||||||
open_im_conversation
|
open_im_conversation
|
||||||
|
open_im_third
|
||||||
open_im_cron_task
|
open_im_cron_task
|
||||||
open_im_cmd_utils
|
open_im_cmd_utils
|
||||||
${msg_gateway_name}
|
${msg_gateway_name}
|
||||||
|
@ -15,6 +15,7 @@ service_filename=(
|
|||||||
open_im_auth
|
open_im_auth
|
||||||
${msg_name}
|
${msg_name}
|
||||||
open_im_conversation
|
open_im_conversation
|
||||||
|
open_im_third
|
||||||
)
|
)
|
||||||
|
|
||||||
#service config port name
|
#service config port name
|
||||||
@ -28,6 +29,7 @@ service_port_name=(
|
|||||||
openImAuthPort
|
openImAuthPort
|
||||||
openImMessagePort
|
openImMessagePort
|
||||||
openImConversationPort
|
openImConversationPort
|
||||||
|
openImThirdPort
|
||||||
)
|
)
|
||||||
|
|
||||||
service_prometheus_port_name=(
|
service_prometheus_port_name=(
|
||||||
@ -40,6 +42,7 @@ service_prometheus_port_name=(
|
|||||||
authPrometheusPort
|
authPrometheusPort
|
||||||
messagePrometheusPort
|
messagePrometheusPort
|
||||||
conversationPrometheusPort
|
conversationPrometheusPort
|
||||||
|
thirdPrometheusPort
|
||||||
)
|
)
|
||||||
|
|
||||||
for ((i = 0; i < ${#service_filename[*]}; i++)); do
|
for ((i = 0; i < ${#service_filename[*]}; i++)); do
|
||||||
|
Loading…
x
Reference in New Issue
Block a user