This page is in English — onze technische documentatie voor ontwikkelaars en beheerders is in het Engels.

Relay Laatst gecontroleerd:

Lesson: your domain, the wildcard DNS record

Point your domain at your Viaalink Relay with two DNS records, the domain and its wildcard, so every device name reaches the Relay, and let the Relay check it. The text of the film 'Your domain: the wildcard DNS record'.

Bekijk de film op YouTube (Engels) (2:56) Opent YouTube in een nieuw tabblad.

After this lesson every name under your domain reaches your Relay, and its Domains page shows it green.

You need a sign-in at your DNS provider, and the address of your home connection (or of the server your Relay runs on). In the examples the domain is relay.example.com.

1. Why a wildcard

Every device name sits under your domain: notes, git, photos. You could add a record for each name, but devices pick new names all the time. A wildcard record, *.relay.example.com, covers every name at once.

So you add two records: one for the domain itself, and the wildcard. The wildcard is the one that makes every device name work.

2. CNAME or A record

Both records point at your home connection. Which kind you pick depends on that address:

  • Your provider can change your home address: use a CNAME record. It points at a dynamic DNS name, such as the one your NAS gives you, and that name follows your address.
  • Your address is fixed: an A record pointing straight at it is fine.

Use the same kind for both records.

3. Add the two records

At your DNS provider, add the two records. Most providers want only the part before your own domain, so in the zone example.com the names are relay and *.relay. With a dynamic DNS name such as home.dyndns.example:

TypeNameTarget
CNAMErelayhome.dyndns.example
CNAME*.relayhome.dyndns.example

With a fixed address, use type A for both, with your public IP address as the target.

If your provider offers to proxy a record (on Cloudflare, the orange cloud), switch that off for both. The Relay must receive the traffic itself, or its certificates fail.

4. Let the Relay check

Now let your Relay check it. In the dashboard, open Domains. Under Default DNS target, choose CNAME (or A), and type the same target as in your records. Click Check DNS again.

The Relay makes up a random name under your domain, one nobody created, and looks it up. Only a wildcard can answer for a name like that.

If the wildcard is missing, or has not spread yet, Domains says wildcard record not found. The Overview then turns red: DNS is not resolving for relay.example.com, because devices cannot be reached by name. A new record can take a while. Wait a few minutes.

5. Check again

Then click Check DNS again. Now the wildcard is found, and it points to your target: the domain reads wildcard found. Open the domain, and under DNS records both records read found.

The red row on the Overview is gone.

Recap

  1. One wildcard covers every device name.
  2. A CNAME for an address that changes, an A record for a fixed one.
  3. Two records: relay and *.relay.
  4. The Relay looks up a random name: Check DNS again on Domains.
  5. Not found yet? Wait, and check again until the wildcard is found.

Check yourself

You added only the record for relay.example.com. A device publishes notes. Why does notes.relay.example.com not open, and which record fixes it?

No record covers notes. Add the wildcard *.relay.example.com.

Read on