fix(deploy): 公网 overlay 用 !override 覆盖内部端口绑定
Compose 合并后内部端口只绑 127.0.0.1,避免与基础 0.0.0.0 叠加导致起不来。 顺带给 JPUSH_PUSH_INTENT 加引号,并拒绝空 SERVER_IP。 Co-authored-by: Cursor <cursoragent@cursor.com> Co-authored-by: multica-agent <github@multica.ai>
This commit is contained in:
co-authored by
Cursor
multica-agent
parent
f1fe4a3928
commit
a71f6a0ce1
@@ -9,7 +9,8 @@ MINIO_EXTERNAL_ADDRESS="https://jxd.jinniu.ink/files"
|
||||
OPENIM_PUSH_ENABLE=jpush
|
||||
JPUSH_APPKEY=95fc2352648a7d4568ac8d72
|
||||
JPUSH_PUSH_URL=https://api.jpush.cn/v3/push
|
||||
JPUSH_PUSH_INTENT=intent:#Intent;action=android.intent.action.MAIN;category=android.intent.category.LAUNCHER;component=cn.solsum.jinxunda/cn.solsum.jinxunda.MainActivity;end
|
||||
# 必须加引号:值含分号。compose 读 .env 无妨;不要用 shell source/. 加载未加引号的副本。
|
||||
JPUSH_PUSH_INTENT="intent:#Intent;action=android.intent.action.MAIN;category=android.intent.category.LAUNCHER;component=cn.solsum.jinxunda/cn.solsum.jinxunda.MainActivity;end"
|
||||
|
||||
# Master Secret 由 scripts/load-jpush-secret.sh 从
|
||||
# /root/.config/jinxunda/jpush_master_secret 注入为环境变量 JPUSH_MASTER_SECRET。
|
||||
|
||||
@@ -1,13 +1,16 @@
|
||||
# 公网测试 overlay。用法(在仓库根目录,由总工执行,本卡不跑):
|
||||
# set -a && . ./.env && ./scripts/load-jpush-secret.sh && set +a
|
||||
# ./scripts/load-jpush-secret.sh
|
||||
# docker compose -f docker-compose.yaml -f deploy/public/docker-compose.public.yaml up -d
|
||||
# 不要用 shell source/. 加载 .env:JPUSH_PUSH_INTENT 含分号,未加引号时会被拆成命令。
|
||||
# compose 会自行读取仓库根目录 .env 做变量替换;Master Secret 只经 load-jpush-secret.sh 注入。
|
||||
#
|
||||
# 原则:内部端口只绑 127.0.0.1;对外只开 80/443 + LiveKit 媒体 17881/tcp、17882/udp。
|
||||
# ports 使用 !override,避免与基础 compose 的 0.0.0.0 绑定叠加。
|
||||
# 回滚:去掉本 overlay,改回 docker compose -f docker-compose.yaml up -d,数据目录 components/ 与 data/ 不动。
|
||||
|
||||
services:
|
||||
openim-server:
|
||||
ports:
|
||||
ports: !override
|
||||
- "127.0.0.1:${OPENIM_MSG_GATEWAY_PORT}:10001"
|
||||
- "127.0.0.1:${OPENIM_API_PORT}:10002"
|
||||
environment:
|
||||
@@ -18,18 +21,18 @@ services:
|
||||
- IMENV_OPENIM_PUSH_JPUSH_PUSHINTENT=${JPUSH_PUSH_INTENT}
|
||||
|
||||
minio:
|
||||
ports:
|
||||
ports: !override
|
||||
- "127.0.0.1:${MINIO_PORT}:9000"
|
||||
- "127.0.0.1:${MINIO_CONSOLE_PORT}:9090"
|
||||
|
||||
etcd:
|
||||
ports:
|
||||
ports: !override
|
||||
- "127.0.0.1:12379:2379"
|
||||
- "127.0.0.1:12380:2380"
|
||||
|
||||
livekit:
|
||||
command: --config /etc/livekit.yaml --node-ip ${SERVER_IP}
|
||||
ports:
|
||||
ports: !override
|
||||
- "127.0.0.1:${LIVEKIT_PORT:-17880}:17880"
|
||||
- "${LIVEKIT_RTC_TCP_PORT:-17881}:17881"
|
||||
- "${LIVEKIT_RTC_UDP_PORT:-17882}:17882/udp"
|
||||
@@ -37,7 +40,7 @@ services:
|
||||
- ./config/livekit.public.yaml:/etc/livekit.yaml
|
||||
|
||||
account-server:
|
||||
ports:
|
||||
ports: !override
|
||||
- "127.0.0.1:${ACCOUNT_PORT:-10010}:10010"
|
||||
|
||||
edge:
|
||||
|
||||
Reference in New Issue
Block a user