2021-05-08 02:39:26 +08:00
|
|
|
---
|
|
|
|
name: SOA
|
|
|
|
parameters:
|
|
|
|
- name
|
|
|
|
- ns
|
|
|
|
- mbox
|
|
|
|
- refresh
|
|
|
|
- retry
|
|
|
|
- expire
|
|
|
|
- minttl
|
|
|
|
- modifiers...
|
2023-01-13 05:59:42 +08:00
|
|
|
parameter_types:
|
|
|
|
name: string
|
|
|
|
ns: string
|
|
|
|
mbox: string
|
|
|
|
refresh: number
|
|
|
|
retry: number
|
|
|
|
expire: number
|
|
|
|
minttl: number
|
|
|
|
"modifiers...": RecordModifier[]
|
2021-05-08 02:39:26 +08:00
|
|
|
---
|
|
|
|
|
|
|
|
`SOA` adds an `SOA` record to a domain. The name should be `@`. ns and mbox are strings. The other fields are unsigned 32-bit ints.
|
|
|
|
|
2023-03-14 04:30:21 +08:00
|
|
|
{% code title="dnsconfig.js" %}
|
2023-01-20 20:56:20 +08:00
|
|
|
```javascript
|
2021-05-08 02:39:26 +08:00
|
|
|
D("example.com", REG_THIRDPARTY, DnsProvider("DNS_BIND"),
|
2023-02-07 22:25:41 +08:00
|
|
|
SOA("@", "ns3.example.org.", "hostmaster@example.org", 3600, 600, 604800, 1440),
|
2021-05-08 02:39:26 +08:00
|
|
|
);
|
2022-02-18 01:22:31 +08:00
|
|
|
```
|
2023-03-14 04:30:21 +08:00
|
|
|
{% endcode %}
|
2021-05-08 02:39:26 +08:00
|
|
|
|
2023-03-17 11:14:47 +08:00
|
|
|
If you accidentally include an `@` in the email field DNSControl will quietly
|
|
|
|
change it to a `.`. This way you can specify a human-readable email address
|
|
|
|
when you are making it easier for spammers how to find you.
|
2021-05-08 02:39:26 +08:00
|
|
|
|
2023-02-07 22:25:41 +08:00
|
|
|
## Notes
|
2021-05-08 02:39:26 +08:00
|
|
|
* The serial number is managed automatically. It isn't even a field in `SOA()`.
|
|
|
|
* Most providers automatically generate SOA records. They will ignore any `SOA()` statements.
|
2023-03-17 11:14:47 +08:00
|
|
|
* The mbox field should not be set to a real email address unless you love spam and hate your privacy.
|
2021-05-21 23:35:43 +08:00
|
|
|
|
2023-03-16 06:43:57 +08:00
|
|
|
There is more info about `SOA` in the documentation for the [BIND provider](../../providers/bind.md).
|