From 355f8f74daa392e8a7cc00feea6dda3836f9f7a0 Mon Sep 17 00:00:00 2001 From: tt Date: Thu, 24 Apr 2025 12:50:59 +0800 Subject: [PATCH] docs: update Makefile --- Makefile | 14 +++++++------- docker-compose.yaml | 36 +++++++++++++++++++++++++++--------- 2 files changed, 34 insertions(+), 16 deletions(-) diff --git a/Makefile b/Makefile index 02df8b0..82218c7 100644 --- a/Makefile +++ b/Makefile @@ -17,16 +17,16 @@ deploy-arm: docker push wukongim/wukongim:latest-arm64 deploy-v2-dev: docker build -t wukongim . --platform linux/amd64 - docker tag wukongim registry.cn-shanghai.aliyuncs.com/wukongim/wukongim:v2.1.4-20250319-dev-jsonrpc - docker push registry.cn-shanghai.aliyuncs.com/wukongim/wukongim:v2.1.4-20250319-dev-jsonrpc + docker tag wukongim registry.cn-shanghai.aliyuncs.com/wukongim/wukongim:v2.1.5-20250424-dev + docker push registry.cn-shanghai.aliyuncs.com/wukongim/wukongim:v2.1.5-20250424-dev deploy-v2: docker buildx build -t wukongim . --platform linux/amd64,linux/arm64 - docker tag wukongim registry.cn-shanghai.aliyuncs.com/wukongim/wukongim:v2.1.3-20250210 - docker tag wukongim wukongim/wukongim:v2.1.3-20250210 - docker tag wukongim ghcr.io/wukongim/wukongim:v2.1.3-20250210 + docker tag wukongim registry.cn-shanghai.aliyuncs.com/wukongim/wukongim:v2.1.4-20250319 + docker tag wukongim wukongim/wukongim:v2.1.4-20250319 + docker tag wukongim ghcr.io/wukongim/wukongim:v2.1.4-20250319 docker tag wukongim ghcr.io/wukongim/wukongim:v2 - docker push registry.cn-shanghai.aliyuncs.com/wukongim/wukongim:v2.1.3-20250210 - docker push wukongim/wukongim:v2.1.3-20250210 + docker push registry.cn-shanghai.aliyuncs.com/wukongim/wukongim:v2.1.4-20250319 + docker push wukongim/wukongim:v2.1.4-20250319 docker push ghcr.io/wukongim/wukongim:v2 deploy-latest-v2: docker build -t wukongim . diff --git a/docker-compose.yaml b/docker-compose.yaml index 4f584df..d834ef9 100755 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -1,15 +1,33 @@ -version: '3.1' +version: '3.7' services: - wukongim: - image: wukongim/wukongim:v2 - restart: always + wukongim: # WuKongIM服务 + image: registry.cn-shanghai.aliyuncs.com/wukongim/wukongim:v2 + environment: + - "WK_CLUSTER_NODEID=1001" + - "WK_CLUSTER_SERVERADDR=xx.xx.xx.xx:11110" # 节点内部通信请求地址 + - "WK_TRACE_PROMETHEUSAPIURL=http://prometheus:9090" # prometheus监控地址 + - "WK_MODE=release" # release模式 + - "WK_EXTERNAL_IP=xxx.xxx.xxx.xxx" # 服务器外网ip + - "WK_CLUSTER_APIURL=http://xx.xxx.xxx.xx:5001" # api的内网地址 + - "WK_INTRANET_TCPADDR=xx.xx.xxx.xx:5100" # tcp连接的内网地址,此配置主要用于压测 + healthcheck: + test: "wget -q -Y off -O /dev/null http://localhost:5001/health > /dev/null 2>&1" + interval: 10s + timeout: 10s + retries: 3 + restart: always volumes: - - ~/wukongim:/root/wukongim + - ./wukongimdata:/root/wukongim # 数据挂载到物理机的目录 ports: - 5001:5001 # http api 端口 - 5100:5100 # tcp端口 - 5200:5200 # websocket端口 - - 5300:5300 # monitor端口 - - 5172:5172 # monitor端口 - - \ No newline at end of file + - 5300:5300 # 管理端端口 + - 5172:5172 # demo端口 + - 11110:11110 # 分布式节点通讯端口 + prometheus: # 监控服务 + image: registry.cn-shanghai.aliyuncs.com/wukongim/prometheus:v2.53.1 + volumes: + - "./prometheus.yml:/etc/prometheus/prometheus.yml" + ports: + - "9090:9090" \ No newline at end of file