I had ``` const reactApp = new sst.ReactStaticS...
# help
d
I had
Copy code
const reactApp = new sst.ReactStaticSite(this, "ReactSite", {
      path: "frontend",
      customDomain: {
        domainName: '<http://app.new-site.com|app.new-site.com>',
        domainAlias: '<http://www.app.new-site.com|www.app.new-site.com>',
        hostedZone: '<http://new-site.com|new-site.com>'
      },
    });

    const gatsbyApp = new sst.StaticSite(this, "Site", {
      path: "website",
      customDomain: {
        domainName: '<http://new-site.com|new-site.com>',
        domainAlias: '<http://www.new-site.com|www.new-site.com>',
        hostedZone: '<http://new-site.com|new-site.com>'
      },
    });
and decided to separate the stacks Now I get
Copy code
Resource handler returned message: "Invalid request provided: One or more of the CNAMEs you provided are already associated with a different resource. (Service: CloudFront, Status Code: 409, Request ID: d2fe1c2a-7aa1-4542-9d03-b78a2db46429, Extended Request ID: null)" (RequestToken: f67da444-ad4e-a853-5a59-6324d3ebc0ac, HandlerErrorCode: InvalidRequest)
in my Seed deploy. Really all that does is just deploy
sst deploy --stage dev
. My understanding of what’s happened is that because it’s a different stack it ‘thinks’ the gatsby site is different. If that’s correct then my next move is to re-do the cname because it’s associated with the wrong cloudfront distrobution or something. Is there an SST command to do such a thing? Or is the correct course
sst remove --stage dev
and that will remove the CName records etc…
f
Hey @Devin, this error often happens when the domain is already in use.
d
yes. I had deployed this a few times already
f
Yeah you can either remove the other site, or remove the custom domain setting in the other site.
d
K i just tried
npx sst remove --stage dev
and then pushed to git -> seed again
🤞
IT WORKED! 🎉