mirror of
https://github.com/StackExchange/dnscontrol.git
synced 2025-02-26 16:42:56 +08:00
Add a "commented SPF record" example.
This commit is contained in:
parent
bf664a9f44
commit
b0333f3244
1 changed files with 8 additions and 2 deletions
|
@ -59,7 +59,7 @@ D('example.com', REG, DnsProvider('R53'),
|
|||
)
|
||||
{% endhighlight %}
|
||||
|
||||
## Macro to group repeated records
|
||||
## Macro to for repeated records
|
||||
|
||||
{% highlight javascript %}
|
||||
|
||||
|
@ -74,17 +74,19 @@ var GOOGLE_APPS_RECORDS = [
|
|||
CNAME('mail', 'ghs.googlehosted.com.'),
|
||||
CNAME('groups', 'ghs.googlehosted.com.'),
|
||||
CNAME('sites', 'ghs.googlehosted.com.'),
|
||||
CNAME('start', 'ghs.googlehosted.com.'),
|
||||
]
|
||||
|
||||
D('example.com', REG, DnsProvider('R53'),
|
||||
GOOGLE_APPS_RECORDS,
|
||||
A('@', '1.2.3.4')
|
||||
)
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
## Add comments along complex SPF records
|
||||
|
||||
You can't normally put comments in the middle of a string,
|
||||
You normally can't put comments in the middle of a string,
|
||||
but with a little bit of creativity you can document
|
||||
each element of an SPF record this way.
|
||||
|
||||
|
@ -102,6 +104,10 @@ var SPF_RECORDS = TXT('@', [
|
|||
'~all'
|
||||
].join(' '));
|
||||
|
||||
D('example.com', REG, DnsProvider('R53'),
|
||||
SPF_RECORDS,
|
||||
)
|
||||
|
||||
{% endhighlight %}
|
||||
|
||||
## Dual DNS Providers
|
||||
|
|
Loading…
Reference in a new issue