fix(deploy): 部署前解绑遗留 Custom Domain——wrangler 改路由形态不会自动解绑 - #67
Merged
Conversation
真机第二发现:wrangler 成功写入 zone 路径路由(core <domain>/* 与 模块 <domain>/m/<id>/* 均已生效),但旧 Custom Domain 绑定原样保留 (workers/domains 实测 core 主域与 hello 子域两条都在)——同 host 上 Custom Domain 优先于路径路由,模块路由被吞、冒烟 module:hello 失败, DNS 自建还撞 81062(Workers 管理的记录仍占位)。 - dns.ts:findAccountId(GET /accounts 首个)+ removeLegacyCustomDomains (幂等删 hostname==domain 或 *.domain 的绑定,CF 同步删自建 DNS 记录) - steps.ts:core 部署前清理(cleanupCustomDomains 注入口),顺序: Custom Domain 清理 → core deploy → DNS 自建 → 模块部署 → registry - 测试:dns 新增 4 用例(账户发现 2、清理 2);steps 顺序断言更新 Signed-off-by: huangyinghui <18666119673@163.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
真机第二发现(#66 部署后)
wrangler 成功写入 zone 路径路由(实测:
<domain>/*→ unself-core-api、<domain>/m/hello/*→ unself-module-hello 均在),但旧 Custom Domain 绑定原样保留(workers/domains 实测 core 主域与 hello 子域两条都还在)——wrangler 改路由形态不会自动解绑。后果链:Custom Domain 优先于路径路由 → 模块路由被 core 吞 → 冒烟
module:hello失败;且 DNS 自建撞 81062(Workers 管理的记录仍占位)。修法
findAccountId(GET /accounts 首个)+removeLegacyCustomDomains(幂等删 hostname==domain 或 *.domain 的绑定,CF 同步删自建 DNS 记录)cleanupCustomDomains注入口),顺序:清理 → core deploy → DNS 自建 → 模块部署 → registry验证
全仓三件套绿(deploy 58 用例)。真机验证紧随其后。