1
0
mirror of https://github.com/StackExchange/dnscontrol.git synced 2024-05-11 05:55:12 +00:00

DOCS: Inline creds.json.tpl-example.txt example (#1784)

This commit is contained in:
Jeffrey Cafferata
2022-10-31 20:59:29 +01:00
committed by GitHub
parent 010ba5682a
commit ae1eb970f5
6 changed files with 22 additions and 5 deletions

4
.gitignore vendored
View File

@ -3,8 +3,8 @@ dnscontrol-Darwin
dnscontrol-Linux
dnscontrol.exe
dnscontrol
dnsconfig.js
creds.json
/dnsconfig.js
/creds.json
ExternalDNS
docs/_site
powershell.log

View File

@ -202,7 +202,24 @@ This example requires the [1Password command-line tool](https://developer.1passw
but works with any shell command that returns a properly formatted `creds.json`.
In this case, the 1Password CLI is used to inject the secrets from
a 1Password vault, rather than storing them in environment variables.
An example of a template file containing Linode and Cloudflare API credentials is available here: [creds.json.tpl-example.txt]({{ site.github.url }}/assets/creds.json.tpl-example.txt))
An example of a template file containing Linode and Cloudflare API credentials is available here: [creds.json](https://github.com/StackExchange/dnscontrol/blob/master/docs/assets/1password/creds.json).
```json
{
"bind": {
"TYPE": "BIND"
},
"cloudflare": {
"TYPE": "CLOUDFLAREAPI",
"apitoken": "op://Secrets/Cloudflare DNSControl/credential",
"accountid": "op://Secrets/Cloudflare DNSControl/username"
},
"linode": {
"TYPE": "LINODE",
"token": "op://Secrets/Linode DNSControl/credential"
}
}
```
## Don't store secrets in a Git repo!

View File

@ -60,7 +60,7 @@ use BIND for DNS service, it is useful for testing.
domains, and so on.
Start your `dnsconfig.js` file by downloading
[dnsconfig.js-example.txt]({{ site.github.url }}/assets/dnsconfig.js-example.txt))
[dnsconfig.js](https://github.com/StackExchange/dnscontrol/blob/master/docs/assets/getting-started/dnsconfig.js)
and renaming it.
The file looks like:
@ -126,7 +126,7 @@ It is only needed if any providers require credentials (API keys,
usernames, passwords, etc.).
Start your `creds.json` file by downloading
[creds.json-example.txt]({{ site.github.url }}/assets/creds.json-example.txt))
[creds.json](https://github.com/StackExchange/dnscontrol/blob/master/docs/assets/getting-started/creds.json)
and renaming it.
The file looks like: