Azure / Azure/static-web-apps

[Bug] Cannot generate TXT validation code if custom domain is already used

Open
#609 8 comments 4 reactions 0 assignees View on GitHub
Dominant language
No language data
Stars
346
Forks
67
PR merge metrics
No merged PRs in 30d

Description

**Describe the bug**

I'm trying to migrate a custom domain I own, currently used on a SWA created for a test environment, to another SWA used for production.

When I'm trying to generate the TXT validation code in the production SWA, I get this error:
![image](https://user-images.githubusercontent.com/593151/136962828-cf0a8293-a974-4d5f-b0f9-a72b369f696e.png)

The error exists whether CNAME or TXT validation was used previously on the other (test) SWA.
TXT validation use case was specifically to avoid issues like this to allow for async validation scenarios without downtime, but in the case of SWA to SWA domain name transfer it's broken.

This is VERY problematic as the only workaround is to remove the custom domain from the old SWA (test), way for the DNS to be updated (takes 24-48h), then generate then TXT validation codes on the new SWA (production), with the validation taking 24-48h due to DNS propagation.

That means a lot of forced downtime, just to simply transfer a domain name usage.

**Expected behavior**
You should be able to generate TXT validation code for custom domains in SWA whether the domain name is already used or not. Then you can do the DNS migration without downtime.

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.