Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/noahbailey/ansible-bind
Ansible role for managing bind9 DNS servers
https://github.com/noahbailey/ansible-bind
ansible-role bind9
Last synced: about 1 month ago
JSON representation
Ansible role for managing bind9 DNS servers
- Host: GitHub
- URL: https://github.com/noahbailey/ansible-bind
- Owner: noahbailey
- License: gpl-3.0
- Created: 2019-07-17T01:48:04.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2021-03-19T02:09:06.000Z (almost 4 years ago)
- Last Synced: 2024-11-10T18:48:54.329Z (3 months ago)
- Topics: ansible-role, bind9
- Language: HTML
- Size: 17.6 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ansible-bind
Ansible role for managing bind9 DNS serversThis role takes data from ansible variables and uses it to set up bind9 (debian flavour) DNS.
Currently, this role only configures servers and zones. It does not yet handle replication in primary/secondary systems.
## Usage
Add this role to the `roles` directory in your ansible project.
Then, include the role using a top level playbook:
```yaml
- name: DNS Servers
hosts: dns-servers
become: true
roles:
- ansible-bind
```## Variables
This role requires these variables to exist in inventory:
#### 1. bind (sever config)
This establishes the basic parameters of the server, such as where to send requests, and where to respond to them from.
```
bind:
trusted_subnets:
- 10.11.12.0/24
forwarders:
- 1.1.1.1
- 1.0.0.1
```#### 2. zones
This defines the individual zones that the server will host.
zones is structured as a list of maps, meaning that each one will be separately rendered into a bind database file.
Note that the first NS record is automatically created using the `primary_ns` key, which is used to also construct the SOA record.
Each record will be placed into the file exactly as it is in the list, so formatting is important.
Example:
```yaml
- name: onetwoseven.one
primary_ns: dns1.onetwoseven.one
records:
- '@ IN A 10.204.11.20'
- 'dns1 IN A 10.204.10.11'
```