fix(deploy): 稳定边缘到站点的固定入口
主机本地访问跨站点 NodePort 时 kube-proxy 会随机选择不可达的对端 Pod,导致约四分之一请求被拒绝。为两地应用绑定仅位于 WireGuard 地址的 HostPort 31088/31178,双 NGINX 和集群验收改用该固定入口;原 NodePort 30088/30178 继续保留。端口处于现有公网 DROP、wg0 私网放行范围。\n\n验证:kubectl kustomize、服务端 dry-run、bash -n、ShellCheck、Secret 与 digest 静态检查、git diff --check。
This commit is contained in:
@@ -331,11 +331,11 @@ AI_GATEWAY_ACTIVATE_WORKERS=false \
|
||||
|
||||
for site_ip in 10.77.0.1 10.77.0.2; do
|
||||
cluster_ssh "$CLUSTER_NINGBO_HOST" \
|
||||
"curl -fsS --max-time 10 http://$site_ip:30088/api/v1/healthz >/dev/null"
|
||||
"curl -fsS --max-time 10 http://$site_ip:31088/api/v1/healthz >/dev/null"
|
||||
cluster_ssh "$CLUSTER_NINGBO_HOST" \
|
||||
"curl -fsS --max-time 10 http://$site_ip:30088/api/v1/readyz | grep -q '\"ok\":true'"
|
||||
"curl -fsS --max-time 10 http://$site_ip:31088/api/v1/readyz | grep -q '\"ok\":true'"
|
||||
cluster_ssh "$CLUSTER_NINGBO_HOST" \
|
||||
"curl -fsS --max-time 10 http://$site_ip:30178/ | grep -q 'EasyAI AI Gateway'"
|
||||
"curl -fsS --max-time 10 http://$site_ip:31178/ | grep -q 'EasyAI AI Gateway'"
|
||||
done
|
||||
|
||||
"$script_dir/install-nginx-edges.sh" activate
|
||||
|
||||
@@ -31,8 +31,8 @@ k3s kubectl rollout status deployment/easyai-api-hongkong -n easyai --timeout=30
|
||||
k3s kubectl set env deployment/easyai-api-ningbo -n easyai \
|
||||
AI_GATEWAY_ASYNC_QUEUE_WORKER_ENABLED=false >/dev/null
|
||||
k3s kubectl rollout status deployment/easyai-api-ningbo -n easyai --timeout=300s
|
||||
curl -fsS http://10.77.0.1:30088/api/v1/readyz | grep -q '"ok":true'
|
||||
curl -fsS http://10.77.0.2:30088/api/v1/readyz | grep -q '"ok":true'
|
||||
curl -fsS http://10.77.0.1:31088/api/v1/readyz | grep -q '"ok":true'
|
||||
curl -fsS http://10.77.0.2:31088/api/v1/readyz | grep -q '"ok":true'
|
||||
REMOTE
|
||||
|
||||
credentials_file=$(mktemp "$cluster_root/.local-secrets/cluster/e2e.XXXXXX")
|
||||
|
||||
Reference in New Issue
Block a user