Platform email: outbound-only custom domain for an apex whose MX belongs to another provider
Maintainer thường phản hồi trong vòng 1 ngày
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức phù hợp với người mới
- 35/100
- Loại issue
- Tính năng
- Độ rõ ràng
- Khá rõ ràng
- Mức độ hoạt động
- Sôi nổi
- Công nghệ
- typescript
Hướng nghiên cứu
Start with connection-service.ts and connection-schema.ts, then trace the setup steps and outbound refusal handling described in the issue. Check the migration and compatibility digest flow, operator route and CLI entry points, and the named integration tests. Done means outbound-only routes can send without enabling inbound routing, existing managed routes retain their behavior, and the CLI, documentation, status, and sync handle the new mode.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Use case
We run a self-hosted Void platform serving several brands whose apex domains use Microsoft 365 for mail. Each brand wants its apps to send as [email protected], with the brand's existing mailboxes left alone. Inbound mail for that address must keep going to Microsoft 365; Void should never receive it.
Today the only ways to send from a custom domain on the platform are to give Void the whole apex (including inbound) or to use the shared sender domain. For these brands the first is impossible and the second changes the visible sender address. The same applies to apexes hosted on Google Workspace.
Problem
Platform-managed custom domains are all-or-nothing:
- Registration refuses any apex that has MX records, including Cloudflare's own Email Routing MX on a fresh assignment:
connection-service.tsL1459-L1474 ("already has MX records; use an unused domain apex or a platform shared email address"). - Even without that check, setup enables Email Routing and a catch-all for the apex (
SETUP_STEPS, L104-L115:routing_enable,catchall_ensure,inbound_probe, ...). Enabling Email Routing makes Cloudflare publish its own MX records, which would collide with the mailbox provider's.
The refusal is the right default for inbound. The gap is that there is no way to say "outbound only": Email Sending onboarding and the sender check do not need inbound at all.
Proposal
Add a per-route inbound mode, additive and defaulting to today's behaviour:
email_domain_routes.inbound_mode text not null default 'managed', with values'managed' | 'none', through a new additive migration.drizzle/compatibility.jsonrecords schema digests, so it would need the usual entry.- For
inbound_mode = 'none', setup runs['sending_onboard', 'publish']. It skips the MX/routing preflight,routing_enable,catchall_ensure,inbound_probeand the ingress and secret steps. - Admin-only, since the domain's mail then lives outside Void's checks. CLI:
void platform email domain-add <apex> --project <slug> --outbound-only. Owner-managed registration is unchanged. - The Email Sending refusal path must change for these routes. Today a definitive refusal from Cloudflare is downgraded to
outbound_status = 'verified_only'and setup continues (connection-service.tsL3265-L3303). That fallback makes sense when inbound is the point of the domain. For an outbound-only route it would leave a domain that can send only to verified recipients and does nothing else, so the operation should fail with the refusal instead. - Inbound stays closed without extra code.
requireCurrentReceiptRouterequiresroute.inbound_status === 'ready'(admission.tsL885), and an outbound-only route never leavespending. Sender admission already needs only an active route owned by the project,outbound_statusofreadyorverified_only, a healthy connection and a usable credential (admission.tsL392-L407), so it should work unchanged.
Touchpoints I would expect, with tests:
platform/packages/api/src/email/connection-schema.ts(column), a newdrizzle/00NN_*.sqlmigration, andcompatibility.json.connection-service.ts: step selection, preflight bypass, and thesending_onboardfailure mode. Alsostatusandsyncfor these routes, so a missing inbound is not reported as an error.domain-service.tsand the operator route and CLI (operator-args.ts,operator-cmd.ts), plusdocs/reference/cli/platform-email.mdanddocs/guide/platform/administration/email.md, as AGENTS.md asks for new CLI flags.- Integration tests in
email-connections.test.ts,email-admission.test.tsandoperator-email-domains.test.ts, plus the migration/upgrade-compatibility unit test.
Happy to send a PR for this if the direction is acceptable.
Questions for maintainers
- Is
inbound_mode: 'managed' | 'none'the shape you would want, or would you model it differently (for example a separate route kind)? - Should owner-managed routes (the
void email domain addflow) get this too, or should it stay administrator-only? - DMARC handling on a fresh apex: a Microsoft 365 apex usually already publishes SPF and DMARC records, and the guide notes that existing DMARC or bounce-domain records can block Email Sending onboarding. Should the operation fail with a checklist, or is there a supported way to coexist? We would rather fail loudly than send unauthenticated mail.
- Should outbound-only also accept a subdomain of the zone? Custom inbound needs the apex because of the catch-all, but sending does not.
Related: #509 (the docs/behaviour mismatch for apexes with foreign MX).
- Ngôn ngữ chính
- TypeScript
- Star
- 402
- Fork
- 32
- Merge trung bình
- 11 giờ 52 phút
- Pull request đã merge (30 ngày)
- 88
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của voidzero-dev/void
-
bug
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 78/100
voidzero-dev/void#428 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 5/5 Hơn một tuần Mức phù hợp với người mới 35/100
voidzero-dev/void#511 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 58/100
voidzero-dev/void#509 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 55/100
voidzero-dev/void#507 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 55/100
voidzero-dev/void#506 ·
Maintainer thường phản hồi trong vòng 1 ngày
Tất cả issue của voidzero-dev/void
Issue tương tự
-
area:editor bug issue-form:bug P0 platform:windows review: low
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 64/100
1lck/Lithe-IDEA#1388 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
fix(api): isToolAuditEnabled swallows database read errors on auditToolOperations without loggingĐang mởarea: backend bug priority: low
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
snapotter-hq/SnapOtter#3238 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
rig up --plan times out after 5 s and reports an UNKNOWN outcome while the daemon completes the planĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
Maintainer thường phản hồi trong vòng 1 ngày
-
filesystem: search_files does not expand non-wildcard excludePatterns like directory_tree doesĐang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 72/100
modelcontextprotocol/servers#5216 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 76/100
Maintainer thường phản hồi trong vòng 1 ngày