Domain-Connect / Templates

Templates for use in the Domain Connect Protocol
64 stars 201 forks source link

[SmugMug] remove usage of %fqdn% template var; add subdomain template #552

Closed bwg closed 2 months ago

bwg commented 2 months ago

GoDaddy does not support the %fqdn% builtin variable, which serves as a shortcut to [host.]domain

https://github.com/Domain-Connect/spec/blob/master/Domain%20Connect%20Spec%20Draft.adoc#692-variable-values

Instead, use "www.%domain%" as the redirect target for the domain template. Additionally use an absolute value for the CNAME host, effectively ignoring any host provided when applying the template. (see note on absolute trailing dot here: https://github.com/Domain-Connect/spec/blob/master/Domain%20Connect%20Spec%20Draft.adoc#53-template-record)

The host field for the "REDIR301", may not do anything, as its unclear from the docs whether it is considered for a REDIR301 context (though other templates use it), but it specifies an absolute host as well, effectively hard coding the redirect to be from %domain% > www.%domain%. In the event that host is ignored here, it's not a big deal because we dont pass a host when applying so the end result will be the same. It's more for correctness of the template.

Additionally, a second, subdomain specific template was created. This template will only be applied to subdomains (ie. photos.mysite.org). There is no redirect associated with it.

Other changes:

github-actions[bot] commented 2 months ago

Linter OK:

Linter result for smugmug.com.custom-subdomain.json
Linter result for smugmug.com.custom-domain.json