Using the dns-primary component #28
Replies: 2 comments 1 reply
-
Yes absolutely. For example # stacks/orgs/dev.yaml (for the sake of an example)
components:
terraform:
dns-primary:
vars:
domain_names:
- dev-example.com # stacks/orgs/prod.yaml (for the sake of an example)
components:
terraform:
dns-primary:
vars:
domain_names:
- prod-example.com
I'm not sure I understand the question, but you can create a delegated domain very easily with # stacks/orgs/dns.yaml (for the sake of an example)
components:
terraform:
dns-primary:
vars:
domain_names:
- example.com # stacks/orgs/dev.yaml (for the sake of an example)
components:
terraform:
dns-delegated:
vars:
zone_config:
- subdomain: marketing.dev
zone_name: example.com Although alternatively I would suggest making the hosted zone only # stacks/orgs/dev.yaml (for the sake of an example)
components:
terraform:
dns-delegated:
vars:
zone_config:
- subdomain: dev
zone_name: example.com |
Beta Was this translation helpful? Give feedback.
-
NOTE: This was originally posted in sweetops.slack.com but was asked to post here and has been slightly modified from the original for additional context and clarity.
Our current DNS architecture consists of 2 primary top level domains:
example.com
- vanity domainexample.internal
- service discovery domain. only applicable to the stage, no need to share these records ever. If we need to expose a service we use the vanity domain. This zone is always private in our environment.Each stage owns a hosted zone for both domains. For the dev stage this would be
dev.example.com
anddev.example.internal
.Using
account-map
we have defineddns_account_account_name
(btw, why not just name this vardns_account_name
🙂), which forces creation of dns-primary zones in the dns account. This works well for public routable TLDs requiring delegation of subdomains, but not strictly necessary for ourexample.internal
domain.As a solution we define
example.internal
in a global stagedns-primary
component:Zone creation of
example.internal
is not strictly required, but if we expect to usedns-delegated
, this zone has to exist in our DNS account. Chalk this up to "good enough; move on"... for now.Questions
dns-primary
outside of the dns account using the existing published ?marketing.dev.example.com
, what's the recommended approach whendev.example.com
is a delegated domain created usingdns-delegated
?Beta Was this translation helpful? Give feedback.
All reactions