oscarcarlsson / ansible-knot

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Ansible Role: knot

This role will fully configure and install knot.

GitHub Workflow Status GitHub issues GitHub release (latest by date)

Requirements & Dependencies

not known

Operating systems

Tested on

  • Debian 9 / 10
  • Ubuntu 20.04
  • CentOS 8
  • OracleLinux 8
  • ArchLinux
  • FreeBSD 13.0

configuration

default

knot_user: knot
knot_group: knot

knot_config: {}

knot_zones: {}

knot config

knot_config:
  server:
    listen:
      - '127.0.0.1@5353'

  log:
    syslog:
      any: debug

  database:
    storage: "{{ knot_database }}"

  template:
    default:
      storage: "{{ knot_database }}"
      file: "%s.zone"

  zone:
    molecule.local: {}

knot zones

knot_zones:
  state: present
  molecule.local:
    ttl: 3600
    soa:
      primary_dns: 'dns.molecule.local'
      hostmaster: 'hostmaster.molecule.local'
      refresh: 6h
      retry: 1h
      expire: 1w
      minimum: 1d
    name_servers:
      dns.molecule.local:
        ip: '{{ ansible_default_ipv4.address }}'
    records:
      router.molecule.local:
        type: 'A'
        ip: '{{ ansible_default_ipv4.address }}'

      ldap.molecule.local:
        type: 'CNAME'
        target: 'router.molecule.local'

knotc CLI

knotc conf-begin
knotc conf-set zone.domain molecule.local
knotc conf-commit

knotc zone-begin molecule.local
knotc zone-set molecule.local @ 7200 SOA dns hostmaster 1 86400 900 691200 3600
knotc zone-set molecule.local dns 3600 A 172.17.0.2
knotc zone-set molecule.local router 3600 A 172.17.0.2
knotc zone-set molecule.local www 3600 A 172.17.0.5
knotc zone-set molecule.local ldap 3600 CNAME router
knotc zone-set molecule.local _https._tcp 3600 SRV "10 20 433 www"
knotc zone-commit molecule.local

more under knot operation doku

Author and License

  • Bodo Schulz

License

Apache

FREE SOFTWARE, HELL YEAH!

About

License:Apache License 2.0


Languages

Language:Python 60.5%Language:Jinja 39.5%