feat: support wildcard custom domains in gateway by kvinwang · Pull Request #545 · Dstack-TEE/dstack

@kvinwang

Add fallback to `_dstack-app-address-wildcard.{parent}` TXT record
when exact `_dstack-app-address.{sni}` lookup fails. This allows a
single TXT record to route all subdomains of a custom domain to the
same app, while still allowing per-subdomain overrides via exact records.

@kvinwang

The else branch used ? operator which returned error immediately on
exact lookup failure, preventing the wildcard fallback from executing.
Use if-let instead to fall through gracefully.